Skip to content

How to integrate Google Analytics data into Attio

Google Analytics tells you where website visitors come from. It does not, on its own, tell you which of those visitors became leads, opportunities or paying customers inside your CRM. Bridging that gap means capturing source context at the moment a form is submitted and storing it on the resulting Attio record. This guide walks through the four-step setup, explains exactly which data points get passed, and maps each captured field to the reports it unlocks.

Why bridge analytics and CRM at all?

Analytics tools are strong at measuring traffic and on-site behaviour. They are weaker at following an individual through a sales process that happens partly offline. When the source information lives only in the analytics platform, you can count sessions but you cannot easily answer questions such as how many customers came from a specific Google Ads campaign or how much revenue a blog post produced.

Putting the same source context onto the CRM record closes that loop. Once channel and landing-page values sit alongside the lead's name, email and phone number, you can group, filter and aggregate by marketing source using whatever reporting layer you prefer — Attio's own reporting or an external tool such as Looker Studio or Microsoft Power BI.

How the capture mechanism works

The approach relies on a small script placed on your website. On each visit it inspects the same kinds of signals an analytics platform would use, classifies the visit into a marketing channel, and writes the result into a cookie in the visitor's browser. When that visitor later submits a form, the values are read from the cookie and placed into hidden fields on the form. Those hidden fields then travel with the submission into Attio.

The channel categories mirror the ones you would recognise from Google Analytics — Paid Search, Paid Social and Organic Search among them. Because the classification happens at visit time and is stored client-side, the values persist across pages until the form is submitted.

The four-step setup

The setup breaks into four sequential stages. Each stage depends on the one before it, so work through them in order.

Step 1 — Add hidden fields to your lead forms

Identify every form on your site that captures lead information — a contact form, a quote request form, a demo request form. On each one, add the following hidden fields:

  • Channel
  • Channel Drilldown 1
  • Channel Drilldown 2
  • Channel Drilldown 3
  • Landing Page
  • Landing Page Group

Most form builders support hidden fields natively. If you use Gravity Forms, Typeform or Jotform, dedicated walkthroughs exist for adding them. The important point is that the field names must match exactly, because the script populates them by name.

Step 2 — Let the script populate the fields

Once the hidden fields exist, the script writes the visitor's source data into them automatically. Consider a visitor who arrives from a Paid Search brand campaign. Depending on the UTM parameters attached to the ad, the fields would populate roughly as follows:

  • Channel = Paid Search
  • Channel Drilldown 1 = Google
  • Channel Drilldown 2 = Brand Campaign
  • Channel Drilldown 3 = Attio

Separately, the visitor's first landing page (for example, a features page URL) and its page group (for example, Features) are also captured. This gives you two levels of landing-page granularity: the exact page and the broader section it belongs to.

Step 3 — Pass the data into Attio

When the form is submitted, the channel and landing-page values are sent into Attio together with whatever the lead typed into the visible fields — name, email, phone and so on. The result is a single Attio record that carries both contact details and marketing source context. You can route this into the standard person or company object, or into any other object your workflow requires.

Step 4 — Build reports on top of the data

With source data now living on CRM records, reporting becomes a matter of grouping and aggregating. You can use Attio's built-in reporting or export to a third-party tool such as Looker Studio or Microsoft Power BI. Typical questions the data can answer include which channels produce the most leads, which campaigns generate the most customers, and how much revenue is attributable to organic search.

What data actually lands in Attio

Two categories of information are passed through, and it helps to understand each separately.

Marketing channel data

The channel itself is captured — Paid Search, Paid Social, Organic Search and so on. Beyond the top-level channel, further detail is recorded depending on the channel type. For Paid Search, that means campaign, ad group and keyword. This is what makes the drilldown fields useful: they let you move from a broad channel view down to a specific campaign or keyword.

Landing page data

The first page a lead sees is recorded, along with the category that page belongs to. For example, a blog post URL would be captured as the landing page, with Blog as its group. This two-level structure lets you report on a whole content section — how many leads came from the blog — and then drill into individual posts within it.

Field-to-report map

The table below shows which captured field feeds which of the four example reports described later. Use it to check that your hidden fields are wired correctly before you start building dashboards.

Four reports worth building first

The following reports are a practical starting set. Each one uses a different slice of the captured data, so together they exercise the full field set.

1. Leads by channel

Group leads by the Channel field and count them per month. This shows which channels are producing volume and whether your budget allocation matches where leads actually come from. A useful pattern to watch for is a channel that delivers steady lead volume but receives a small share of spend — that gap often signals an underfunded winner. Conversely, a channel with heavy spend and thin lead counts is worth a hard look at targeting or creative before you renew the budget.

2. Opportunities by Google Ads campaign

Group opportunities by Channel Drilldown 2 (the campaign level) and count them. This distinguishes campaigns that generate real sales conversations from campaigns that generate traffic but no deals. It is a more useful signal than click volume alone.

3. Customers by Facebook Ads network

Facebook ads can appear across Facebook, Instagram, Messenger and WhatsApp. Grouping customers by the network that delivered the ad shows which placement produces paying customers, which in turn informs where to shift budget.

4. Revenue from organic search by search engine

If you invest in SEO — whether through an agency or in-house — grouping revenue by search engine shows the return on that investment and whether continued spending is justified. It answers a question that traffic reports alone cannot: which search engines send visitors who actually convert into revenue.

Pre-launch checklist

Before you rely on the data, confirm each of the following:

  • Every lead-capturing form has all six hidden fields, spelled exactly as listed.
  • The script is present on every page where a form can be submitted, not just the homepage.
  • A test submission from a tagged URL produces the expected channel and drilldown values on the resulting Attio record.
  • The landing page and landing page group fields populate with the first page visited, not the form page.
  • Your reporting tool can read the Attio fields you intend to group by.

If a test submission shows blank attribution fields, the usual cause is a field-name mismatch between the form and the script. If the fields populate but the values look wrong, check the UTM parameters on the ad — the drilldown values are derived from them.

Getting started

For organisations already using Attio, adding source context to each lead record turns the CRM into a marketing measurement tool as well as a sales tool. The setup involves a script on the site, six hidden fields on each form, and a reporting layer of your choice. Before committing, it is worth checking the current plan options and onboarding details directly with the provider, since trial length, pricing and typical setup time can change and should be confirmed against the latest published terms rather than assumed.

Captured field to report mapping
Captured fieldWhat it holdsReport it feeds
ChannelTop-level marketing channel (e.g. Paid Search, Organic Search)Leads by channel
Channel Drilldown 1First level of detail (e.g. Google)Leads by channel; opportunities by campaign
Channel Drilldown 2Second level (e.g. campaign name)Opportunities by Google Ads campaign
Channel Drilldown 3Third level (e.g. ad group or keyword)Opportunities by Google Ads campaign
Landing PageFirst page the lead sawContent-level lead and customer reports
Landing Page GroupCategory of that first page (e.g. Blog)Section-level lead and customer reports

Field names and drilldown behaviour reflect the captured setup described in the source article; confirm current form-builder and Attio field behaviour before relying on them.

Frequently asked questions

How is this different from just looking at Google Analytics?

Google Analytics measures sessions and on-site behaviour. This setup attaches source context to the CRM record itself, so you can follow a lead through to opportunity and customer status and attribute revenue to a channel or campaign. The two views complement each other rather than replace one another.

Why are the hidden fields blank on some submissions?

The most common cause is a field-name mismatch: the hidden field on the form must be named exactly as the script expects. A second cause is a missing script on the page where the form lives. Test with a tagged URL and inspect the resulting record to isolate which of the two is happening.

Which page is recorded as the landing page?

The first page the visitor sees on your site, not the page where the form is submitted. The page group is the category that page belongs to — for example, a blog post URL is recorded with Blog as its group.

Can I report outside Attio?

Yes. The data sits on Attio records, so you can use Attio's built-in reporting or connect a third-party tool such as Looker Studio or Microsoft Power BI.