How do I add analytics to a Lovable app?
19 September 2026 · by Nordva, who make Nordva Launch
The short answer
Lovable already counts visitors, page views, sources and countries for a published app, but it doesn't read UTM tags or follow a visitor to a signup or a payment. For that, copy your script tag from Nordva Launch, ask Lovable's chat to add it to the head of every page, publish the change, and list your lovable.app address in Launch.
Add Nordva Launch web analytics to this app. 1. Add the script tag I paste at the end of this message to the <head> of every page, exactly as given. Don't change its attributes and don't load it twice. 2. Add data-nordva-goal="signup" to the main signup or "Get started" button, so clicks on it count as a goal. 3. Don't add any other analytics, cookie banner or tracking code, and don't change anything else. 4. Tell me which files you changed. The script tag:
What Lovable already measures
Every published Lovable app has an Analytics view in the editor, switched on by default. It shows visitors, page views, views per visit, visit duration and bounce rate, with lists of traffic sources, top pages, devices and countries (worked out from each visitor’s browser time zone). It costs nothing and needs no setup, so look there first.
Lovable’s docs are clear about what it leaves out. It “does not read UTM parameters”, and it measures traffic, not people: it doesn’t recognise a visitor who comes back, or follow one to a signup. So it can’t tell two Reddit posts apart, and it can’t say which source brought the people who paid. For campaigns and funnels, Lovable itself points to a dedicated analytics tool.
Step by step
-
Get your script tag. Sign in to Nordva Launch and open Insights. The setup card shows your tag with your site id filled in. It looks like this:
<script defer src="https://e.nordva.dev/v1/s.js" data-site="ste_…"></script> -
List your domains. On the same card, add the addresses your visitors use: your
yourapp.lovable.appaddress, and your own domain if you connected one. Launch counts visits only from the domains you list, so clicks inside Lovable’s editor preview don’t count unless you add that address too. -
Paste the prompt. Copy the prompt above into Lovable’s chat and paste your tag at the end of it. Let the chat make the change rather than editing files yourself; on Lovable’s Free plan the code editor is read-only anyway. Apps created since 13 May 2026 run on TanStack Start with server rendering, older ones on React with Vite, and the page head lives in a different file in each. That’s why the prompt says “every page” instead of naming a file.
-
Publish. Lovable’s live site doesn’t change until you open the Publish dialog and click Publish changes.
-
Check it. Open the published app in a new tab and click around. The Insights card says “Your first visit is here.” when the first visit arrives, usually within a minute.
What you see after that
Visits by source, including UTM tags and ?ref= on the first page, the pages people read, countries and cities on a map, devices, and how many people clicked your signup button (the goal from step 2 of the prompt). Launch leaves out known bots and visits from data centres, so the numbers are people.
Tag the links you share, such as ?utm_source=reddit&utm_campaign=launch, so two posts on the same site show up as two rows.
The part Lovable can’t do comes next. When a visitor joins your waitlist through a Launch form, or your app calls nordva('identify', { email }) after a signup, Launch links that person to their first visit. Connect Stripe (read-only, on every plan) and Insights shows which sources brought the customers who paid.
Visitors in Europe
New sites start in the auto tracking mode. Visitors outside the EEA, the UK and Switzerland get a first-party cookie, so a returning visitor counts once. Inside them, that only happens after your cookie banner gets a yes; until then their visits are counted without an id. If most of your visitors are in Europe and you want them recognised, add a consent banner and call nordva('consent', true) when someone accepts. The script sets nothing until the server says it may.
Limits
The Free plan includes 10,000 analytics events a month per account and one funnel of up to three steps; Indie includes 100,000 events and five funnels. There’s no time limit on Free and no card needed.
When Launch is the wrong tool
If Lovable's own Analytics view already answers your questions (how many people came, and from which sites), you don't need a second tool yet. Launch is for when you need to know which post, ad or newsletter brought the people who signed up and paid.
- Lovable: Project analytics
- Lovable: How Lovable hosts your app
- Lovable: FAQ (the stack new apps use)
- Lovable: View and edit your project's code
Builders change often. If a step no longer matches what you see, tell us and we will fix the page.
- Does Lovable have analytics?
- How do I track UTM parameters in Lovable?
- How do I add a tracking script to my Lovable site?
- Can Lovable analytics track custom events?