What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
GA4 campaign attribution and single-page-app page views are two separate problems. Preserve the UTM parameters through the landing URL and make sure GA4 collects them when the session begins; then configure Next.js route changes to send exactly one virtual page_view each. A route-change event can improve page reporting, but it cannot restore campaign values that were lost before collection.
Why UTM attribution and SPA page views fail differently
A campaign link may arrive with utm_source, utm_medium and utm_campaign. GA4 maps those manual tags to traffic-source dimensions, including manual source, medium and campaign. The values need to be present when the landing session is collected: GA4’s session_start carries attribution information such as UTM parameters, GCLID and referrer. See Google’s manual tagging documentation and session documentation.
As an Amazon Associate I earn from qualifying purchases.
Next.js client-side navigation changes the browser-visible route without loading a new document. That creates a separate measurement question: does the analytics setup send a page view for each route transition? Missing route page views can leave page reports incomplete; duplicate route page views can inflate them. Neither situation, by itself, explains whether the original campaign tags reached GA4.
Both failures can happen at once. Diagnose in order: inspect the tagged URL and redirects, verify the first analytics collection, configure route-change measurement once, then select the acquisition dimension that answers your question.
#1 Best Overall
1. Check the campaign URL and every redirect
Confirm the intended UTM values
Start with the link used in the campaign and verify that the final destination is intended to carry utm_source, utm_medium and utm_campaign. Use consistent spelling and capitalization: values that differ in case can be reported as separate values, making campaign data harder to interpret. Google documents how manual parameters map to GA4 traffic-source dimensions in its manual tagging reference.
Trace the full landing path
Follow the link through each redirect and inspect the URL at every destination, including the address bar after the page finishes loading. A marketing redirector, URL shortener, proxy, server or client-side navigation can drop or alter the query string. Google’s troubleshooting guidance identifies redirects and JavaScript or server-side behavior as possible causes of parameter loss.
- Compare the original campaign URL with each redirect destination and the final browser URL.
- Check redirect rules, middleware, proxy configuration and client-side code for query-string removal or URL replacement.
- If the final landing URL no longer contains the tags, fix that path before changing route tracking.
Direct/(none) is not proof of a Next.js router defect. It can reflect missing or stripped tags, a genuinely direct or offline visit, a shortener or redirect path, or ad-blocking and other collection limitations. Google’s direct traffic troubleshooting page discusses these possibilities.
Recommended Free Tools
Rank #2
2. Verify what GA4 collects on the landing session
Once the final URL is correct, confirm that the analytics tag is installed and runs on the landing page while the campaign parameters are still available. GA4 documents session_start as carrying session attribution information such as UTM parameters, GCLID and referrer; see About Analytics sessions.
- Test a landing visit using a representative tagged URL, not only an internal navigation to the same page.
- Check the first analytics collection and its landing-page location against the final browser URL.
- If the first tracked session lacks campaign identifiers, investigate tag loading, consent behavior, redirects and parameter handling on that initial visit.
Changing how later route changes send page views does not retroactively restore UTM values that were stripped or unavailable before the session was collected.
3. Choose one route-change page-view strategy
For an SPA, decide whether the current Google tag setup already measures browser-history changes or whether the application needs a manual route-change event. Google’s single-page application guide describes history-change triggers and virtual page_view events. It explicitly advises disabling automatic history-based page views if you send those events manually, to avoid double-counting.
| Approach | When it may fit | Main check |
|---|---|---|
| Automatic history-based measurement | The installed Google tag setup already observes browser-history changes and its behavior is verified. | Confirm a route transition produces one page_view, with the expected page_location. |
| Manual route-change measurement | The implementation needs explicit route handling or custom control over the virtual page location. | Disable the corresponding automatic history-based page views, then confirm one event per intended transition. |
Neither approach is universally best. Check what the current tag deployment already does, whether you need custom page-location or referrer handling, and how the chosen approach fits your App Router or Pages Router implementation. The Next.js integration guidance on Google’s third-party libraries page is versioned for Next.js 14; verify details against the version and integration in your project.
4. For the App Router, observe route state in a Client Component
Next.js provides usePathname to read the current pathname in a Client Component. Its usePathname reference, last updated February 27, 2026, demonstrates observing pathname and search parameters in an effect.
A manual implementation can use an effect that responds to usePathname and, when relevant, useSearchParams. Treat query-string changes as page views only if your application considers them distinct views. Before sending events, check whether initial-load tracking already sends the first page_view; otherwise, an effect that fires on initial render can duplicate it.
Rewrites can make the browser-visible path differ from the source path used during prerendering. Next.js cautions that this can cause a hydration mismatch when pathname-dependent UI is rendered. Keep client-only route observation aligned with the browser-visible route and handle hydration-sensitive behavior as described in the Next.js pathname guidance. There is no single universal code snippet for every router, tag manager and Google tag configuration.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.5. Prevent duplicates and validate in DebugView
For a manual Google Tag Manager setup, Google’s SPA guide documents a pattern using a history-change trigger, a Google Tag update that merges configuration while suppressing an immediate duplicate page view, and a GA4 Event tag that sends page_view. The guide says not to add page_referrer to that update example: GA4 handles the original external referrer on initial load and can populate the previous virtual URL for navigation pathing. This is a documented GTM pattern, not a requirement for every Next.js implementation; see Google’s SPA measurement guide.
PC Slower Than It Used to Be?
A free scan shows the junk files, broken settings and background clutter dragging Windows down - then fixes them in one click.Free scan · Windows 10 & 11Outdated Drivers Are Slowing You Down
One free scan finds every outdated or missing driver and matches the right update for your exact hardware.Free scan · exact hardware match- Open the site’s tag setup in its preview or debugging mode.
- Load a tagged landing URL and verify the landing collection separately from later navigation.
- Navigate through representative routes and inspect GA4 DebugView for one expected
page_viewper intended transition. - Check each event’s
page_locationagainst the route visible in the browser, and investigate missing or repeated events before relying on page-view totals.
Google recommends preview and DebugView verification in its SPA guide. A healthy route-event count alone does not demonstrate that campaign parameters were collected at session start; test tagged landings and internal navigation as separate cases.
6. Read the acquisition report with the right scope
GA4 traffic-source dimensions have user, session and event scopes. They answer different questions and their values are not interchangeable. Google’s traffic-source dimensions documentation explains that user- and session-scoped dimensions use paid and organic channels last click, while event-scoped dimensions use the selected attribution model, which is data-driven by default.
| Dimension scope | Question it answers | Example dimension |
|---|---|---|
| User | How was this user first acquired? | First user source / medium |
| Session | Which source or campaign brought this session? | Session source / medium |
| Event | Which channel receives credit for a key event under the selected attribution model? | Event-scoped attribution dimensions |
If the question is about the campaign that started a particular visit, inspect session acquisition. If it is about a person’s original acquisition, inspect first-user acquisition; for key-event credit, use the event-scoped attribution view. A difference across these dimensions is not, on its own, evidence that the UTM tag failed.
Quick Recap
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.
Quick wins for a faster PC:
Repair Windows errors before they cause bigger problemsFix Now →Scan for outdated or missing drivers - takes under a minuteDriver Scan →Clear out junk files and repair common Windows errorsFree Scan →




