GA4 is now the normal Google Analytics setup
The original version of this page was written while websites were migrating from Universal Analytics to Google Analytics 4. Advice about running both systems until July 2023 is no longer useful for a new installation.
GA4 uses an event-based measurement model. Page views, sessions, clicks, downloads, purchases and other interactions are represented through events and event parameters.
Create the account, property and web data stream
- Open Google Analytics and create an account if you do not already have one.
- Create a GA4 property for the website or business you want to measure.
- Under the property, add a Web data stream.
- Enter the website URL and stream name.
- Copy the Measurement ID, which normally begins with
G-.
A data stream is the connection between your website and the GA4 property. Once the site is tagged, website interactions can be sent to that stream and used in GA4 reports.
Install the Google tag or use Google Tag Manager
Google currently recommends Google Tag Manager as a flexible way to manage Google Analytics tagging, especially when the site will later need additional events or other tags.
A website can also install the Google tag directly. For manual installation, Google instructs site owners to place the tag
immediately after the opening <head> element on each page that should be measured.
<body>.
Follow the current installation instructions shown for your web data stream.
Many CMS platforms provide a field where you only need to enter the Google tag ID. If your CMS has an official/native Analytics integration, follow that platform's current setup instructions instead of duplicating the tag manually.
Verify the implementation before trusting the reports
After installation, confirm that the site is actually sending data. Google's current troubleshooting guidance recommends tools such as Realtime, DebugView and Tag Assistant.
| Tool | What to check |
|---|---|
| Realtime | Confirm that recent visits and events are arriving in the property. |
| DebugView | Inspect events and parameters while testing a specific implementation. |
| Tag Assistant | Check whether the Google tag is loading and identify tagging problems. |
| Browser developer tools | For technical troubleshooting, inspect network requests and JavaScript errors. |
Realtime data can appear quickly, while standard reports may need additional processing time. Do not assume a tag is broken simply because a standard report has not populated immediately.
Understand the four practical types of GA4 events
Automatically collected
Events such as first_visit, session_start and user_engagement can be collected automatically after basic setup.
Enhanced measurement
Common web interactions such as scrolls, outbound clicks and file downloads can often be measured without custom code when enhanced measurement is enabled.
Recommended events
Google defines recommended event names for common actions such as purchases, sign-ups and logins so reporting can use consistent conventions.
Custom events
Use a custom event when the interaction you need to measure is not adequately represented by an automatic, enhanced or recommended event.
Mark important actions as key events
GA4 uses the term key event for an event that represents an action especially important to your business. Depending on the site, that could be a purchase, lead form submission, sign-up, booking or another meaningful outcome.
Avoid marking every minor interaction as a key event. The purpose is to make important outcomes easier to evaluate across traffic sources and user journeys.
A practical reporting map for website owners
| Question | GA4 area |
|---|---|
| Is data arriving right now? | Realtime |
| Where did sessions come from? | Acquisition / Traffic acquisition |
| Which pages are attracting visits? | Engagement reports and landing-page/page reports |
| Which important actions are being completed? | Events and key-event reporting |
| I need a custom breakdown or filter | Explore / Explorations |
GA4 Explorations are useful when a standard report does not provide the exact dimensions, segments or filters needed for an analysis.
Use GA4 to investigate referral traffic from AI tools
Some visits from tools such as ChatGPT, Gemini, Perplexity, Claude and Copilot can appear as referral traffic when referral information is available. The amount you can identify is limited because not every AI-generated visit carries a clean, unique referral source.
See our dedicated tutorial on tracking AI traffic in GA4 for source filtering, landing-page analysis and the limitations of trying to identify every AI-assisted visit.
Analytics implementation is also a privacy decision
Your GA4 setup should match the privacy, consent and data-protection requirements that apply to your users and organization. Do not send personally identifiable information to Analytics, and make sure consent behavior is tested if you use Consent Mode or a consent-management platform.
Problems worth checking before blaming GA4
- The tag is missing from some page templates.
- The wrong Measurement ID or property is being used.
- The same Google tag is accidentally installed more than once.
- Consent settings prevent the tag from firing during the test.
- Internal traffic or data filters remove the traffic you are expecting to see.
- An ad blocker or privacy extension changes the result during testing.
- Custom events use inconsistent names or parameters.
- A key event is marked incorrectly or too broadly.
A good GA4 setup starts simple
Begin with a clean property, one correct web data stream and a verified tag. Then measure a small set of meaningful events and key events before building complex dashboards. Reliable measurement is more useful than collecting every possible interaction.