Questions tagged [measurement-protocol]

The Google Analytics Measurement Protocol allows developers to make HTTP requests to send raw user interaction data directly to Google Analytics servers.

This allows developers to measure how users interact with their business from almost any environment. Developers can then use the Measurement Protocol to:

  • Measure user activity in new environments.
  • Tie online to offline behavior.
  • Send data from both the web and server.

Links

351 questions
7
votes
2 answers

Why checkout step not recorded in the Google Analytics report?

I'm making an enhanched ecommerce tracking with google analytics. I'm following the existing implementation in gtag.js. I have 4 checkout steps including shipping method data, payment method data, pending payment, and also paid (purchase). I've made…
7
votes
1 answer

Unable to see Measurement protocol hit in GA reports (using Python Request library)

Trying to send pageview hit using Measurement Protocol to Google Analytics, Universal property (using Python's Requests library to make HTTP request) import requests endpoint = 'https://www.google-analytics.com/collect' payload = {'v':'1' …
Vibhor Jain
  • 1,396
  • 1
  • 11
  • 32
7
votes
1 answer

Sharing Google Analytics ClientID between javascript client and java server

I have been using Google Analytics for basic analytics for my web app - just tracking page impressions using javascript calls like this: ga('create', 'UA-XXXXXXXXX-1', 'mydomain.com');ga('send', 'pageview') This approach has always frustrated me…
6
votes
2 answers

GA4 Measurement protocol IP override

When sending events to GA4 is there a way to override user ip, if using universal analytics you could have passed a user_ip variable uip but for GA4 I dont see a param option to pass user ip. Any help would be appreciated
Rtrader
  • 917
  • 4
  • 11
  • 26
6
votes
1 answer

Google Analytics v4 Measurement Protocol - how to send tech and acquisition data

Background: I am tracking acquisition data to a mobile application. Certain links redirect to App Store or Google Play store through my website, where Google Analytics collects data on those redirects. The mobile application also utilizes a new iOS…
6
votes
1 answer

How to set User Agent in Measurement Protocol (Google Analytics 4)

How to set or override User Agent value in Measurement Protocol (Google Analytics 4)? It was easy with previous Measurement Protocol (Universal Analytics):…
6
votes
0 answers

Firebase Analytics Server Side

Firebase Client (JS) supports Firebase Analytics. In there, I use the method logEvent to log my events to GA v2 and see great funnels. However, some events, like database events, or HTTP requests coming from a 3rd party aren't tracked by the client,…
Amit
  • 5,924
  • 7
  • 46
  • 94
6
votes
1 answer

Google Analytics Measurement Protocol Returned Gif

I'm using the GA measurement protocol, and it's returning a gif file. I'm a little unclear what this file is for - ideally I'd like to be able to send measurement protocol requests as fire and forgets to keep page load times at a minimum. Is it…
Tom Gullen
  • 61,249
  • 84
  • 283
  • 456
6
votes
2 answers

Google measurement protocol transactions not being recorded

I am issuing GET requests as defined in the Google Measurement Protocol from our server to record offline conversions. The following test request (tracking id…
Matt Evans
  • 7,113
  • 7
  • 32
  • 64
5
votes
1 answer

Sending Google Analytics events programatically from server side not working

We want to send custom event tracking information to google analytics from server side. For this I have referred this SO post, and come up with the following code snippet, but somehow it is not sending the events' information to GA. I've debugged…
Yogi
  • 9,174
  • 2
  • 46
  • 61
5
votes
0 answers

How to connect Google Analytics Measurement Protocol (back end) with a front end session? Only via Client ID?

I have a website with Google Analytics tracking on and I have a goal that listens to the event EVENT1. If I open a private tab and go to page P1, I can see it being registered as a landing page. All good. And I visit a second page, P2, and then send…
corgrath
  • 11,673
  • 15
  • 68
  • 99
5
votes
3 answers

Enhanced E-commerce with Measurement Protocol

I have a subscription model and want to track the monthly payments with a server-side call through the Measurement Protocol. The problem now is that I don't know how to build the call because as the documentation states I need a productIndex which I…
5
votes
3 answers

Can't Post Events to Google Analytics from Google App Engine

I am trying to post an event to google analytics using Measurement Protocol from my Google App Engine (Java) web app. I have tested the URL by submitting the URL directly, and it immediately shows up (realtime) in Google Analytics. But when I try to…
5
votes
0 answers

Google Analytics measurement protocol session control not working

I'm trying to use manual session control with the Google Analyitics measurement API, and I cannot get it to work. After a bunch of fiddling, as a basic test case I set up a simple test site in analytics, and manually made the following requests to…
5
votes
1 answer

UserId, CID in measurement protocol

Measurement protocol To Identify a new user vs. returning user , can we use the user id field . ( i.e we can hash username or other identifier unique to the user and associate it with a particular user . This way we can identify new users vs.…
user476566
  • 1,319
  • 3
  • 26
  • 42
1
2
3
23 24