Esta página ainda não foi traduzida para o português, por isso aparece em inglês.

GA4 Request Decoder — Read Google Analytics /g/collect Hits

Debug Google Analytics 4 without guesswork. Copy a /g/collect request from the browser’s Network tab and paste it here — the URL, the request body or both — to see each event, its parameters, user properties, ecommerce items and the consent state (gcs) in plain words.

Atualizado em

In DevTools → Network, filter by collect, then right-click the request → Copy → Copy URL (and Copy request payload for batched events).

Seus dados nunca saem do seu computador. Todo o processamento acontece localmente no navegador.

Como usar: GA4 Request Decoder

  1. Open your site with DevTools → Network and type collect in the filter.
  2. Click something that should send an event, then right-click the /g/collect request → Copy → Copy URL.
  3. Paste it here. If several events were batched, also paste the request payload below the URL.
  4. Read the shared fields (measurement ID, client ID, consent) and each event’s parameters.

What the fields mean

  • tid is the measurement ID, cid the client ID from the _ga cookie, sid the session ID and sct the session count.
  • en is the event name. ep.* are text parameters, epn.* number parameters, up.* and upn.* user properties.
  • pr1, pr2… are ecommerce items, with fields like id, nm (name), pr (price) and qt (quantity) joined by ~.
  • gcs is the consent state: G111 means ad and analytics storage are granted, G100 both denied. _dbg=1 means the hit goes to DebugView.
  • _ss marks a session start, _fv a first visit, _et the engagement time in milliseconds.

These parameters are not officially documented by Google and can change; the decoder labels the ones it knows and lists the rest as they are. Everything runs in your browser. To send your own events, use the GA4 Event Code Generator.

Também pesquisado como: ga4 hit decoder, g/collect parameters, ga4 collect parameters explained, gcs parameter ga4, debug ga4 events, ga4 network request, ga4 debugger.

Ferramentas que combinam com: GA4 Request Decoder

  • Google Tag Snippet Generator — Enter your GA4 measurement ID, Google Ads ID or Tag Manager container ID and get install code that is ready to paste — with Consent Mode v2 defaults, cross-domain linking, debug mode, manual page views and cookie settings switched on only when you need them.
  • Tracking & Pixel Checker — Enter a URL to find every analytics tag, ad pixel and tag manager on the page — with their IDs, what’s loaded inside Google Tag Manager, the cookie consent tool, and Search Console / Bing verification tags.
  • URL Parser — Paste a URL to see every component and decoded query parameter — then edit, add or remove parameters and copy the rebuilt URL.
  • Event Tracking Script Generator — Track button clicks, links and form submits by adding attributes instead of code: data-track="sign_up_click" plus optional data-track-* parameters.

Perguntas frequentes

Why does one request contain several events?
GA4 batches events that happen close together: shared fields are in the URL and each event is a line in the request body. Paste both to see them all.
What does gcs=G100 mean?
Consent Mode is on and both ad_storage and analytics_storage are denied, so the hit is a cookieless ping. After the visitor accepts it changes to G111 (or G101 with only analytics granted).
My event is not in the request — why?
Check the gtag or dataLayer code runs (look for errors in the console), the measurement ID is right and that an ad blocker is not blocking the request.
Posso instalar o GA4 Request Decoder como um aplicativo da web e usá-lo offline?
Sim. O GA4 Request Decoder é um aplicativo da web instalável (PWA) — instalado a partir do seu navegador, não baixado de uma loja de aplicativos. Clique em “Instalar aplicativo” na parte superior desta página no Chrome ou no Edge (Windows, macOS, Linux, ChromeOS) ou, no Android, use “Compartilhar” → “Adicionar à tela inicial” no iPhone e no iPad, ou “Arquivo” → “Adicionar ao Dock” no Safari 17+ em um Mac. Em seguida, ela se abre em uma janela própria com seu próprio ícone e, como é executada inteiramente no seu navegador, continua funcionando offline. O Firefox no desktop não permite a instalação de aplicativos da web. Como funciona a instalação.

Ferramentas relacionadas