+With Google Analytics 4 Web, events are sent from the browser to GA4. If you use Segment’s [Google Analytics 4 Cloud destination](/docs/connections/destinations/catalog/actions-google-analytics-4/#benefits-of-google-analytics-4-cloud) to send events through the API and tie data between client-side and server-side, you need to pass the same Client ID from the browser and the server. To do this, fetch the Gtag-generated **clientId** on the web client and pass it to Segment as a property. For more information, see [Google Analytics 4 destination: User Identification](/docs/connections/destinations/catalog/actions-google-analytics-4/#user-identification) on the next steps. Additionally, when using Gtag, Google generates a session_id and session_number when a session begins. The session_id and session_number generated on the client can be passed as Event Parameters to stitch events sent through the API with the same session that was collected client-side, see [Using Gtagjs and Google Analytics 4 Cloud Destination](/docs/connections/destinations/catalog/actions-google-analytics-4/#using-gtagjs-and-google-analytics-4-cloud-destination) for more information and an example.
0 commit comments