How to Verify Google Analytics Tracking Code Is Working

Cody Schneider8 min read

Installing your Google Analytics tracking code is a great first step, but it’s only half the battle. If the code isn't working correctly, you’re flying blind and collecting absolutely no data. This article will walk you through five simple methods to verify that your Google Analytics 4 tracking code is properly installed and actively sending data, so you can have complete confidence in your setup.

GraphedGraphed

Still Building Reports Manually?

Watch how growth teams are getting answers in seconds — not days.

Watch Graphed demo video

Why Verifying Your Tracking Code is a Non-Negotiable Step

Before jumping into the "how," it's worth understanding the "why." Taking a few minutes to verify your setup is one of the highest-leverage activities you can do after installing Google Analytics. A broken tracking code means you have zero visibility into your website’s performance.

  • Data Integrity: Your strategic decisions are only as good as the data they're based on. Incomplete or inaccurate data leads to flawed assumptions about your visitors and marketing campaigns.
  • Preventing Data Gaps: If your code is broken for a week, that’s a week of data you can never get back. Verifying it immediately after installation prevents these costly blind spots.
  • Marketing ROI: Without accurate tracking, you can't properly attribute traffic, conversions, or revenue to your marketing channels. You won't know if your Facebook Ads, Google Ads, or SEO efforts are actually paying off.

In short, verification ensures the foundation of your entire analytics strategy is solid. Now, let's get into how to do it.

Where to Find Your Google Analytics 4 Tag

To verify the code, you first need to know what you're looking for. In Google Analytics 4, this is primarily your Measurement ID (formatted as G-XXXXXXXXXX) and the full website tag snippet (gtag.js).

Here’s how to find it:

  1. Log in to your Google Analytics account.
  2. Click the Admin gear icon in the bottom-left corner.
  3. In the Property column, click on Data Streams.
  4. Select the data stream for your website. This will open up its details panel.
  5. Your Measurement ID is displayed prominently in the top-right corner. This is the unique identifier for your website's data stream.
  6. If you need the full script, scroll down and click on View tag instructions under the 'Google tag' section. This will show you the full JavaScript snippet you need to place on your site.

Keep your Measurement ID handy, as you'll use it in a few of the verification methods below.

GraphedGraphed

Still Building Reports Manually?

Watch how growth teams are getting answers in seconds — not days.

Watch Graphed demo video

5 Methods to Check if Your Tracking Code is Working

Here are five reliable methods, ranging from incredibly simple to slightly more technical. You don't need to do all of them, but being familiar with a couple will make you a more confident analyst.

Method 1: The Realtime Report (The Easiest Way)

The Realtime report is your best friend for instant verification. It shows you activity that is happening on your site right now. If you can see yourself in this report, your code is working.

Step-by-Step Instructions:

  1. Open your website in a new browser window. It's often best to use an Incognito or Private window to ensure you aren’t being filtered out by ad blockers or other extensions.
  2. In your Google Analytics account, navigate to Reports > Realtime in the left-hand menu.
  3. Look at the "Users in last 30 minutes" card. You should see at least 1 active user. If you're the only one on the site, that user is you!
  4. You can further confirm this by looking at other cards. The "Views by Page title and screen name" card should show the title of the page you are currently viewing. The user location map should show a dot over your city.

If you see your activity in the Realtime report, congratulations! Your basic tracking is working correctly. This is the quickest and most straightforward way to confirm a successful installation.

Method 2: Use Your Browser’s Developer Tools

For a more technical confirmation, you can check if your browser is actually sending data to Google Analytics. This involves looking at the network requests your website makes in the background.

Step-by-Step Instructions:

  1. Navigate to your website.
  2. Right-click anywhere on the page and select Inspect to open the Developer Tools panel.
  3. Find and click on the Network tab.
  4. In the filter or search box at the top of the Network panel, type collect or gtag. This will filter the long list of requests down to only those related to Google Analytics.
  5. With the Network panel still open, refresh your web page.
  6. Look for a successful request in the list. You should see a line-item containing google-analytics.com/g/collect... in its name. The "Status" column should show 200, which means the request was successfully sent and received.

This method doesn't just show that the code is on your site, it confirms that a tracking "hit" was successfully sent to Google's servers. It's an excellent way to debug if for some reason you aren't appearing in the Realtime report.

GraphedGraphed

Still Building Reports Manually?

Watch how growth teams are getting answers in seconds — not days.

Watch Graphed demo video

Method 3: View the Page Source Code

This method confirms that the tracking snippet has been added to your website’s HTML, although it doesn’t confirm that it’s firing correctly. It's a quick, low-tech way to ensure the tag exists where it's supposed to.

Step-by-Step Instructions:

  1. Go to your website.
  2. Right-click on the page and select View Page Source. This will open a new tab showing your site's raw HTML.
  3. Press Ctrl + F (or Cmd + F on a Mac) to open the search function.
  4. Search for gtag.js or your specific Measurement ID (e.g., G-XXXXXXXXXX).

If the search finds the Google tag snippet in your site’s HTML, you know the code is present. Most modern CMSs and website builders (like Shopify, Squarespace, or WordPress plugins) add this for you automatically once you enter your Measurement ID. This method is great for confirming they’ve done their job.

Method 4: Use Google Tag Assistant

Google Tag Assistant is a free tool built specifically for debugging and validating tracking tags like Google Analytics and Google Ads. If you use Google Tag Manager (GTM) to install your code, its built-in "Preview" mode is the gold standard for testing.

For Google Tag Manager Users (Recommended):

  1. Log in to your Google Tag Manager container.
  2. Click the Preview button in the top-right corner.
  3. Enter your website’s URL and click Connect. Your site will open in a new tab with a "Connected!" overlay, and the Tag Assistant debug window will open separately.
  4. Navigate through your website as a user would. In the debug window, look at the "Tags Fired" section. You should see your GA4 Configuration Tag appear.
  5. Click on the tag to inspect all the details that were sent to Google Analytics, including the Measurement ID, page location, and other parameters.

GTM's Preview mode gives you the most detailed view of what's happening and is invaluable for debugging both pageviews and specific event tags (like button clicks or form submissions).

Using the Standalone Tag Assistant:

You can also go to https://tagassistant.google.com/, add your domain, and it will launch a debug session similar to the GTM preview mode, showing you the hits being sent and any potential issues with your configuration.

GraphedGraphed

Still Building Reports Manually?

Watch how growth teams are getting answers in seconds — not days.

Watch Graphed demo video

Method 5: Check Specific Event Tracking

Verifying a pageview is great, but what about the interactions that matter more, like button clicks, video plays, or form submissions? You can verify these custom events just as easily.

  1. Perform the action on your website that should trigger an event. For example, click a tagged "Request a Demo" button or fill out a tracked contact form.
  2. Go back to your GA4 Realtime report.
  3. Look at the Event count by Event name card. You should see the name of your custom event appear in the list within seconds. For example, you might see request_demo_click or form_submit.

Alternatively, if you're using GTM's Preview mode, the event will appear on the left-hand side of the debug window, and you can see exactly which tag fired as a result.

Common Issues & Troubleshooting Steps

If you've tried the methods above and nothing is working, here are a few common culprits:

  • Code in the Wrong Place: The Gtag.js snippet should be placed immediately after the opening <head> tag on every page of your site. If it's placed in the footer (near the closing </body> tag), it might not fire before a user navigates away.
  • Filters Blocking Your Traffic: In your GA Admin settings, check for any active filters. A common one is an IP address filter to exclude internal traffic from your office. If you're testing from the office, that could be why you aren't showing up.
  • Code Conflicts & Plugins: Sometimes other scripts, WordPress plugins, or cookie consent barriers can interfere with Google Analytics. Try temporarily deactivating caching or security plugins to see if your code starts tracking.
  • Data Latency: While the Realtime report is instant, it can take 24-48 hours for data to fully process and appear in standard GA reports like the Traffic acquisition report. Don't panic if you don't see data outside of Realtime on day one.

Final Thoughts

Verifying that your Google Analytics code is firing correctly is a simple yet crucial step. Whether you use the instant feedback of the Realtime report or the detailed diagnostics of Tag Assistant, taking a few moments to confirm your setup ensures you're collecting accurate data - the foundation for all your future marketing decisions and website optimizations.

Once you are confident your data is flowing, the next big challenge is turning that raw data into meaningful insights without spending hours wrangling reports. At https://www.graphed.com/register, we solve this by connecting directly to your data sources like Google Analytics, allowing you to ask questions in plain English and instantly get back real-time dashboards and answers. We believe you should spend your time acting on insights, not manually gathering them, and our platform makes that possible for everyone on your team.

Related Articles