SEO & Analytics 9 min read · Updated November 2026

How to add Google Analytics & Ads tags to your site

Google tags let you measure traffic, understand your visitors, and run ads. Here's what they are, how to get yours, and how to ask Ullbek to add them to every page — then verify they're firing.

Once your site is live, one of the first things most people want to do is connect it to Google. Whether that's Google Analytics (so you can see who's visiting), Google Ads (so your ad campaigns can track conversions), or both — all of it runs through a small snippet of code called a Google tag.

The good news: you don't need to touch any code yourself. You just paste your tag snippet into the Ullbek chat, and the agent adds it to every page of your site automatically.

What is a Google tag?

A Google tag is a short piece of JavaScript that you place on every page of your website. It acts as a bridge between your site and Google's tools. Once installed, it silently sends data — page views, button clicks, form submissions, purchases — to whichever Google product you've connected it to.

Every tag has a unique Measurement ID (or Tag ID) that ties the data to your specific Google account. It looks like this:

Tag ID formats
G-XXXXXXXXXX
Google Analytics 4 (GA4) — tracks page views, sessions, user behaviour, and custom events on your site.
AW-XXXXXXXXX
Google Ads — used for conversion tracking, so your ad campaigns know which clicks led to a sale, sign-up, or enquiry.
GTM-XXXXXXX
Google Tag Manager — a container that holds and manages your other tags in one place, so you can change them in Google without touching your site.

The tag snippet itself is just a few lines. Google provides it to you — all you need to do is get it onto every page of your site, which is exactly where Ullbek comes in.

Step 1 — Get your tag from Google

Before you can add anything, you need to set up the relevant Google product and get your tag snippet. Here's where to find it for each tool:

Google Analytics 4

  1. Go to analytics.google.com and sign in.
  2. If you haven't already, create a new Property for your website.
  3. In the left sidebar go to Admin → Data Streams → your stream → View tag instructions.
  4. You'll see a snippet starting with <!-- Google tag (gtag.js) -->. Copy the whole thing.

Google Ads (conversion tracking)

  1. Go to ads.google.com and sign in.
  2. Click Goals → Conversions → Summary → New conversion action.
  3. Choose Website, set up your conversion, then on the final screen choose "Use Google tag".
  4. Copy the snippet — it'll start with the same <!-- Google tag --> comment and contain your AW- ID.
  5. If Google also shows an event snippet, copy that too. It's what counts a phone call or an enquiry as a conversion — see Count calls and enquiries as conversions.
Already have both?

You don't need to add two separate script tags. One gtag.js script handles everything — just tell Ullbek both IDs and it'll configure them together efficiently.

Step 2 — Paste your tag into the Ullbek chat

This is the easy part. Open your Ullbek project and paste your tag snippet directly into the chat. You can either paste the full snippet Google gives you, or just share the ID — either works.

Example message to Ullbek
Can you add this Google Analytics tag to my site?

<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-XXXXXXXXXX"></script>
<script>...
  gtag('config', 'G-XXXXXXXXXX');
</script>

Ullbek will add the tag to the <head> of every HTML page on your site. If you already have a Google tag installed, it'll add your new ID to the existing script rather than loading a duplicate — which is the correct, efficient way to handle multiple Google products.

All pages, at once

Ullbek adds the tag to every page simultaneously — homepage, blog posts, docs, legal pages, everything. You don't need to mention each page individually.

Step 3 — Verify the tag is firing

Once Ullbek confirms it's done, it's worth double-checking that the tag is actually working. There are two ways to do this — one you can ask Ullbek to do, and one you do yourself in Google.

Ask Ullbek to check

The simplest option — just ask:

Example message to Ullbek
Can you check if the Google tag is firing on this page?

Ullbek will inspect the browser's data layer in real time and tell you whether the tag loaded, which IDs fired, and confirm the order everything ran in. It's the fastest way to get a definitive answer.

Check with Google Tag Assistant

Google's own tool, Tag Assistant, shows every Google tag on a page. It's free and runs in your browser:

  1. Open Tag Assistant

    Go to tagassistant.google.com and sign in with the Google account that owns your tag.

  2. Connect your site

    Click Add domain, enter your published site's address, and click Connect. Your site opens in a new tab.

  3. Click around

    Visit a page or two. If you set up a conversion, do the thing it counts — tap the phone number or send the form.

  4. Read the result

    Back in the Tag Assistant tab you'll see each tag it found, by ID, and what it sent. If your AW- or G- ID isn't there, paste what you see into the Ullbek chat and it'll fix it.

Check with Google Analytics Realtime

If you added a GA4 tag, the simplest end-to-end check is to open Google Analytics → Reports → Realtime. Then open your site in another tab and navigate around. You should see yourself appear in the Realtime report within about 30 seconds.

Preview vs. published site

The tag fires in the Ullbek preview environment but Google Analytics Realtime may filter out local/internal traffic. For a clean check, test on your published site URL (e.g. yoursite.ullbek.site, or your own domain).

Adding multiple tags

If you need both Google Analytics and Google Ads on the same site, you only need one gtag.js script — it can carry multiple configurations. The cleanest approach is to tell Ullbek both IDs in one message:

Example message to Ullbek
Please add both of these Google tags to every page:

— Google Analytics: G-XXXXXXXXXX
— Google Ads: AW-XXXXXXXXX

Ullbek will load the script once using the GA4 ID as the primary, then add a second gtag('config', ...) call for the Ads ID. This is exactly how Google recommends it — no redundant script loads, no conflicts.

Count calls and enquiries as conversions

The Google tag on its own tells Google Ads that someone visited. To see which ads bring you customers, you also tell it what counts as a lead: someone tapping your phone number, sending your quote form, or clicking a booking button. Google calls each of these a conversion.

When you create a conversion action in Google Ads and choose "Use Google tag", Google usually gives you two pieces: the Google tag (the same on every site) and an event snippet for that one conversion. The event snippet looks like this:

An event snippet from Google Ads
gtag('event', 'conversion', {'send_to': 'AW-XXXXXXXXX/AbCdEfGhIjK'});

You don't need to know where it goes. Paste both pieces into the Ullbek chat and say, in your own words, when it should count:

Example message to Ullbek
Please add this Google Ads tag to every page. Count it as a conversion when someone taps our phone number.

<!-- Google tag (gtag.js) --> … (paste the whole thing)

Event snippet: … (paste it here)

Ullbek adds the tag to every page and makes the event fire at the moment you described — every phone link on the site, or the form once it has actually sent. Have several kinds of lead? Make one conversion action for each in Google Ads and send all the snippets in one message, saying which is which. Then ask it to publish, so the change goes live.

Only an ID, no event snippet?

That's fine — send the AW- ID and the conversion label Google shows for the action (the part after the slash), and say what should count. Calls made straight from your ad (the call button in Google's results) are counted by Google itself; they don't need anything on your site.

Once it's live, the conversion's status in Google Ads moves on from Unverified, usually within a day. Conversions only show up for visitors who came from one of your ads, so don't worry if your own test tap isn't counted.

Common questions

Will this slow down my site?

The tag script loads with async, which means it doesn't block the rest of your page from rendering. The performance impact is negligible on modern connections.

Do I need to re-add it if I create a new page?

No. Whenever Ullbek creates a new page on your site, it follows the same template as your existing pages — including the Google tag in the <head>. New pages are covered automatically.

I don't see data in Google Analytics yet — is something wrong?

Standard reports in Google Analytics have a 24–48 hour processing delay. Use Realtime for an immediate check. Also make sure you're looking at your published site, not the Ullbek builder preview.

What about a Meta pixel, a chat bubble or a booking calendar?

Same idea, different tool: paste what it gives you into the chat. See Add a Meta pixel, chat, booking or map.

Can I add Google Tag Manager instead?

Yes — just paste your GTM snippet into the Ullbek chat exactly as you would a GA4 or Ads tag. GTM uses a slightly different format (both a <script> and a <noscript> snippet), and Ullbek will add both in the right places.

"You don't need to touch any code. Paste the snippet into the chat and Ullbek handles the rest — every page, at once."

That's everything you need to get Google's measurement tools running on your site. If you run into anything unexpected, just describe it in the chat — Ullbek can inspect the tag in real time and fix any issues on the spot.

Ready to add your tags?

Open your Ullbek project and paste your Google tag snippet into the chat — it takes about 30 seconds.