Want to track website performance and visitor behavior with precision? Using Google Tag Manager (GTM) to install Google Analytics is one of the most efficient and scalable methods available. Whether you’re new to tag management or just looking for a faster way to add Google Analytics to your site, this guide will walk you through every step.
✅
What You’ll Need
Before we begin, make sure you have:
- A Google Tag Manager account
- A Google Analytics account (preferably GA4)
- Access to your website’s code or CMS (like WordPress, Shopify, etc.)
🛠️
Step 1: Create a Google Tag Manager Account
- Go to https://tagmanager.google.com
- Click “Create Account”
- Enter:
- Account Name (usually your business name)
- Container Name (your website’s domain)
- Choose “Web” as your target platform
- Click Create and accept the terms
📌 You’ll be given two snippets of code to add to your site—one for the <head> and one for <body>. Install them manually, or use a plugin if you’re on WordPress.
📊
Step 2: Create a Google Analytics 4 Property
- Go to https://analytics.google.com
- Click Admin > Create Property
- Follow the steps to name your property and set your time zone
- Under Data Streams, select Web
- Enter your website URL and name the stream
📌 After this, you’ll receive a Measurement ID (e.g., G-XXXXXXXXXX). Keep this handy.
🧩
Step 3: Add GA4 to Google Tag Manager
- Go to your GTM Dashboard
- Click on “Tags” > “New”
- Name your tag (e.g., GA4 Configuration)
- Click “Tag Configuration”, then select “Google Analytics: GA4 Configuration”
- Paste your Measurement ID
- Leave other settings as-is unless you need to customize
- Under Triggering, choose “All Pages”
- Click Save
👁️
Step 4: Preview & Test Your Setup
- Click Preview in the top right corner of GTM
- Enter your website URL and connect the debugger
- Navigate your site while Tag Assistant is running
- Check that the GA4 Configuration tag fires on each page load
🔍 You can also check in Google Analytics:
- Go to Admin > Data Streams > Web
- Click “Realtime” to confirm your visit is being recorded
🚀
Step 5: Publish Your Tag
Once you’re confident the tag is working:
- Return to the GTM dashboard
- Click Submit in the top right
- Add a version name (e.g., “Initial GA4 Setup”) and publish
Congratulations! Your website is now tracking data via Google Analytics using Google Tag Manager.
🧠
Pro Tips
- Want to track specific events (like button clicks, form submissions, or scrolls)? GTM makes this easy with Triggers and Variables.
- Use Google Tag Assistant (a Chrome extension) for easier debugging.
- If migrating from Universal Analytics (UA), don’t just copy old tags. GA4 uses an event-based model, so set it up fresh.
✅
Advantages of Using GTM with GA4
Feature | Benefit |
---|---|
No code editing | Tags are managed in GTM, not in your site’s HTML |
Flexibility | Easily add or remove tags for other tools (e.g., Facebook Pixel) |
Version control | Roll back or test tags before going live |
Scalable | Perfect for agencies or multi-site setups |
📣 Final Thoughts
Setting up Google Analytics through Google Tag Manager is not just a smart choice—it’s the best practice for modern websites. It simplifies your tracking setup, boosts flexibility, and makes it easier to scale as your business grows.
Need help setting it up or customizing your tracking? Crossmedia offers professional analytics and tag management services—so you can focus on growing, not configuring.
Leave a Reply