How to use DebugView report in Google Analytics 4 (GA4)

DebugView report is one of the features that differentiates Google Analytics 4 from Universal Analytics. It allows you or your engineering team to check the new implementations in real-time and correct and fix them accordingly. Moreover, it removes an unnecessary thing to find yourself in the Real-time report we all needed to do in Universal Analytics.  

So, how to use DebugView report in Google Analytics 4 (GA4) and how to activate or enable it. These are the questions I will answer in this article. Let’s get started! 

Why should you use the DebugView report in Google Analytics 4?

So, first of all, the DebugView allows you to see the data (events) you generate in real-time and change, fix, monitor or troubleshoot your implementations.  You can find the DebugView mode in GA4 -> Admin -> DebugView.

Navigate to GA4 DebugView report
How to navigate to GA4 DebugView report

To use the DebugView report in GA4, you should take the following steps:

  1. Understand the value of using this report
  2. Enable debug mode in one of the sources: GTM, GA Debugger Chrome Extension, GTAG.js or App code. 
  3. Learn how to read the DebugView report in Google Analytics 4
  4. Bonus: Set up a developer traffic filter to remove the traffic you generate  

Let’s start with the first one. What’s the value of using GA4 DebugView? 

Firstly, when you implement something on your website or mobile app, you always want to check it before making it live for all your traffic (GTM publishing) to be confident that it won’t break anything and will strictly work as expected. Therefore, you used a Real-Time report in Universal Analytics, and you can use this report in GA4, but how much time do you need to spend to find yourself? I don’t want to spend time at all; I want to see myself in a distance of a few clicks. GA4 DebugView report allows it. 

Secondly, you can use filters (internal traffic filter and the developer traffic filter) in Google Analytics 4, and you won’t see the traffic you generate in the GA4 Real-time report. However, GA4 DebugView will show it anyway. 

As a result, you can still troubleshoot your new product adjustments, and your internal team traffic won’t skew your data! Therefore, this report is so valuable! 

Actually, the complete set-up of GA4 includes implementing these two filters. Therefore, I encourage you to enable them, you can read more about the correct setup in my other article on how to set up GA4.

So, once we understand the value of using the GA4 DebugView, let’s look at how to activate it.

How to activate DebugView report in Google Analytics 4

There are a few methods how to activate DebugView in Google Analytics 4. All of them are based on what product you have and what tool you prefer to enable DebugView in GA4. 

So, for instance, if you have a website and your primary GA4 data stream is the web. Then, you can use Google Analytics Debugger Chrome Extension, Google Tag Manager Preview mode or set up debug mode in GTAG.js. 

The implementation is different if your GA4 has iOS or Android data streams. Let’s look at each of them separately. 

Google Tag Manager Preview Mode

Providing-Website-URL-In-GTM-Preview-Mode
Google Tag Manager Preview Mode can be used to activate DebugView report in GA4

The most basic and most popular way of enabling DebugView is to use Google Tag Manager Preview mode. Everything that you need is to open GTM, click on “Preview”, and provide your website URL. After that, GTM will start to send the necessary parameter into Google Analytics 4 that will help GA to understand that it’s a debug device.

GA Debugger Chrome Extension

Variant 2 - GA Debugger Chrome Extension
Google Analytics Debugger Chrom Extension Page

The next one is to use the GA Debugger Chrome extension you can install in your Chrome browser. After you install it, go to your website and activate it. The extension will start to send “debug mode: true” parameter into GA4, and you can find yourself in the GA4 DebugView report.

Debug Event Parameter in GTM

This option makes more sense when you have an additional staging environment where you can test your implementation, and only after your test them on another environment and GA4 account, you will publish them in your primary GA4 account.

The process of setting it up is easy. You should add an additional event parameter in your GA4 configuration tag. 

Variant 3 - GTM Event Property
GA4 Configuration Tag setup in GTM to activate GA4 DebugView report
  1. Open GTM
  2. Find your GA4 configuration Tag
  3. Add a new field to “Fields to Set’
    1. Field Name – debug_mode
    2. Field Value – true

Once you do it, all your events will be sent into Google Analytics 4 as debug ones.

DebugView with GA4 Measurement Protocol

If you use Measurement Protocol to send events into Google Analytics 4, you should include one event parameter in every event you send.

‘debug_mode': 1

After you include it in every event, you will see all of them in Google Analytics 4 DebugView. Before that, you can use event builder to test how it works.

DebugMode with GA4 Measurement Protocol
DebugMode with GA4 Measurement Protocol

GTAG.js Debug Parameter

If you are using GTAG.js library for Google Analytics 4, you still can use one of the first two methods mentioned above, but you will be able to modify your code on the website to activate DebugView report as well.

To monitor all the events on a page, add a ‘debug_mode’:true parameter to your gtag(‘config’), as shown here:

gtag('config', 'G-12345ABCDE',{ 'debug_mode':true });

Or, if you only want to monitor certain events, add a ‘debug_mode’:true parameter to just those events, for example:

gtag('event', 'xyz', { 'debug_mode':true });

To disable debug mode, exclude the ‘debug_mode’ parameter; setting the parameter to false doesn’t disable debug mode.

Firebase DebugView Configurations (iOS and Android)

If you use GA4 to analyse the data from your mobile app, this section is for you. There is a way how you can achieve the same result.

For iOS devices

To enable Analytics debug mode on your development device, specify the following command line argument in Xcode:

-FIRDebugEnabled

This behavior persists until you explicitly disable debug mode by specifying the following command line argument:

-FIRDebugDisabled

For Android devices

To enable Analytics debug mode on an Android device, execute the following commands:

adb shell setprop debug.firebase.analytics.app PACKAGE_NAME

This behavior persists until you explicitly disable debug mode by executing the following command:

adb shell setprop debug.firebase.analytics.app .none.

How to use DebugView report in Google Analytics 4 

DebugView Instructions
GA4 DebugView Instructions

According to our plan, let’s discuss the third step. It’s how to read the DebugView report in GA4. 

The report consists of the following parts:

  1. Device selector
  2. Minutes stream
  3. Seconds stream
  4. Top Events
  5. User Properties Active Now

The device selector is the first partthathelps you to find yourself and select the right debug device you are using. If two people use the DebugView report simultaneously, you can find yourself using the device selector. For instance, it shows “Apple” for my device.

The second part of the report is the minutes stream. This section shows the details of the events happening every minute during the last 30 minutes. The number in the circle means the number of events that happened in that minute. If you click on the circle, GA4 will show you the details of the events that happened at precisely that time.

The third part is the seconds stream. It is an additional view that allows you to check the details of every event separately. You can analyse “addToCart”, “purchase” and other events you send into GA4 exactly here. It shows you the event and user properties associated with the events. For instance, for “addToCart” it will show you ecommerce data as well.

The fourth part of the report represents the top events. The events that happened the most frequently during the last 30 minutes. It also shows you three circles that represent the total number of events, conversions and errors that happened on your website.

The last part of the report shows user properties. If you are testing the implementation of user properties, you can check them here. For instance, on my report, I am testing the user_id as user property for this specific case, and you can see it on the screenshot. You can test other properties such as user’ subscription, logged-in or not, new or returning, etc.

Why is DebugView not working in Google Analytics 4?

There are a few situations when DebugView doesn’t work in Google Analytics 4. Based on my experience working with clients, there are the following main reasons:

  • You didn’t select your device in the DebugView report. As mentioned early, one of the parts of this report is “Device selector”. You should select your device first, and then your data will appear.
  • You didn’t enable DebugMode in the events you sent into Google Analytics 4. It’s a widespread practice, and I usually resolve 90% of cases with this. Please review your code, send a few more events, wait 10-30 seconds, refresh GA4 DebugView, and remember to select your device. 
  • Visited a few pages of your website or app, don’t stay only on one page. Sometimes this works for me. There is a delay, and more data will speed up DebugView to load. 
  • You use any browser extensions to block Google Analytics 4. Therefore Google Analytics 4 can’t receive any data. For instance, the popular ad blocker stops GA4 as well. So, check your browser extensions. Moreover, if you use Brave browser or something similar, it will block everything by default. 
  • If you send data into GA4 via a server-side GTM container, you should use Google Tag Manager Preview Mode. GA Debugger Chrome Extension won’t work.
  • If you use GA4 filters, activate them all. You shouldn’t leave them in “testing” mode. It can prevent the GA4 DebugView report from working. 

If you tried all of that and it didn’t help, don’t hesitate to contact me to resolve the issue. 

GA4 DebugView report limitations

GA4 DebugView doesn’t have any limitations in terms of its functionality, sometimes, it’s tricky to select your device when many people use it, but apart from that, it’s an excellent report that you can use to check your new implementations. 

Final Word

In this article, I explained how to activate and use the DebugView report in Google Analytics 4. After you start to use it, I recommend you set up the internal and developer traffic filter in GA4 to remove the traffic your team generate from GA4 reports and be able to troubleshoot your new product features. 


Frequently Asked Questions

How to use DebugView report in GA4?

DebugView reports require sending the necessary parameter into GA4. The easiest way to activate it is to use GTM Preview Mode or Google Analytics Debugger Chrome Extension. 

How do I add a device to the GA4 DebugView report?

There are a few ways how to add your device to GA4 DebugView. Some of them are:
1. Use GTM Preview Mode
2. Install and use GA Debugger Chrome Extension 
3. Implement “debug mode: true” line into GTAG.js code 
4. Specific the debug mode in the App code. 

Why is DebugView not working in GA4?

The most common reason why the DebugView is not working is because you didn’t activate it properly. To activate it, you should send “debug_mode : true” parameter in Google Analytics 4. The easiest way is to use Google Tag Manager Preview Mode or Google Analytics Debugger Chrome Extension. 

Leave a comment

Your email address will not be published. Required fields are marked *