Check if your tracking works correctly
When you need to check if tracking works on your website correctly, you can use two methods: debug mode in Tag Manager or an inspector tool in the browser.
In this article, we’ll explain how to work with those methods.
Use debug mode in Tag Manager
To check tracking in debug mode, follow these steps:
- Go to Menu > Tag Manager.
- From the website picker, choose a website or app you want to work with.
- In the top-right corner click Debug.
- Your website will open in a new tab with debug mode running.
- Check if the container is installed on the page.
Tip: To open debug mode, you can also add
?_stg_debug at the end of your website’s URL.
- Sync: on or off. It should be on, if you use the container for synchronous tags.
- Async: on. It should be always on. It shows the status of the container for asynchronous tags.
Piwik PROwas fired.
All page views. You may also need to check trigger’s conditions.
stg.pageViewelement on the event list and click on it.
Use inspector tool in the browser
To check tracking using an inspector tool in the browser, follow these steps:
- Open your website.
- Right click on any element on the website and click Inspect or Inspect Element, depending on the browser you’re using.
- Navigate to Network.
- Refresh the browser.
- Find the
ppms.phpelement on the network list.
ppms.phpand check the following items:
Tip: You may see two types of
ppms.php?ping=. Action-name is a request of page view. Ping is a request that checks if the visitor’s session is still active. The frequency of the ping is set in Piwik PRO tag settings.
- Status is 200 OK. This means that tracking works correctly.
- Request URL is the name of your account (instance) in Piwik PRO.
- Website ID is the ID that should match the one used in your account (instance) in Piwik PRO.
Tip: To find a website ID in Piwik PRO, follow these guidelines.
_paq: if the call returns
_paq.pushtracking is working correctly.
_paq.push(['trackPageView']);: if returns undefined tracking is working correctly.
Tip: Using an inspector tool you can also check cookies set by Piwik PRO in your browser. Navigate to Application > Cookies and look for cookies listed here.
Reasons for broken tracking
If you run into a broken tracking on your website, then one of the following issues may cause that:
- Piwik PRO tag, which is responsible for tracking, is disabled.
- Trigger for the Piwik PRO tag is incorrect. It should be set as
All page viewsusually with no additional conditions.
- Tracking code is not installed on your website properly. For more about installing a tracking code, read this article.