# Google Analytics (GA4)

Forward form views, engagement, and submissions to your Google Analytics 4 property.

> ℹ️ **Available on the Free plan.**


## Google Analytics (GA4)

Send form_view, form_engaged, and form_submit events to your own GA4 property through Measurement Protocol.

<h2 id="before-you-start">What you need</h2>

<ul>
  <li>A GA4 property with a Web data stream</li>
  <li>
    Measurement ID, formatted like <code>G-XXXXXXXXXX</code>
  </li>
  <li>Measurement Protocol API secret for that stream</li>
</ul>

<h2 id="connect">Connect GA4</h2>

<h2 id="events">Events and parameters</h2>

<p>
  Every event carries <code>form_id</code>, <code>form_name</code>, and <code>source</code> (<code>link</code> or <code>request</code>).
  Depending on what is known about the visit, an event can also include:
</p>

<ul>
  <li>
    <code>country</code>, <code>device</code>, and <code>browser</code>
  </li>
  <li>
    <code>traffic_source</code>, <code>traffic_source_name</code>, <code>traffic_medium</code>, and <code>traffic_campaign</code>
  </li>
  <li>
    <code>referrer_host</code>
  </li>
  <li>
    <code>duration_seconds</code> on submit, when available
  </li>
</ul>

<p>
  formbase maps its pseudonymous visitor ID to GA4 <code>client_id</code>. When no ID is available, it sends <code>unknown</code>. Events
  never contain answers or respondent email.
</p>

<h2 id="reporting">Use events in GA4</h2>

<ul>
  <li>
    Check <strong>Reports → Realtime</strong> after sending a test or opening a live form.
  </li>
  <li>
    Use <strong>Reports → Engagement → Events</strong> after GA4 finishes processing events.
  </li>
  <li>Create an Exploration filtered to the three formbase event names.</li>
  <li>
    Register parameters such as <code>form_id</code>, <code>device</code>, or <code>traffic_source</code> as custom dimensions.
  </li>
  <li>
    Mark <code>form_submit</code> as a key event if submission completion is a conversion for your business.
  </li>
</ul>

> ⚠️ **Do not send answers to GA4**
> <p>
>     Google Measurement Protocol policies prohibit personally identifiable information. formbase never offers answer streaming for GA4. Use
>     Axiom when you need an opt-in full-submission destination.
>   </p>

<h2 id="troubleshooting">Troubleshooting</h2>

<h2 id="next-steps">Next steps</h2>

<div class="not-prose grid gap-3 sm:grid-cols-2">
  - [Analytics streaming](/integrations/analytics-streaming) — Defaults, privacy, and per-form controls
  - [Built-in analytics](/submissions-analytics/analytics-insights) — Use formbase analytics without external setup
</div>
