Skip to content

Integration: Staging / dev sites

It’s common for websites to use a staging (also called “development”) environment to test code and preview posts before they’re released publicly. Often, these sites are implemented as subdomains of the site domain.

Including the JavaScript with a production Site ID on such a staging site can cause problems with the numbers that reports, the validator tool, the link between URLs and posts in’s analytics engine, and more. This is because staging URLs often disappear or change without warning, and are typically not accessible to the public.

Reach out to to receive a sandbox Site ID that you can use for testing purposes.

Can I test on a staging/dev site?

Testing on a Staging/Development Site

You can! The best way to test on a staging/dev site is to reach out to your account manager or to set up a separate sandbox dashboard and Site ID. When you integrate tracking on your staging/dev site, make sure you set the Site ID to the sandbox Site ID associated with the staging dashboard. This will help avoid staging URLs showing up in your production dashboard and API results. Additionally, articles can be tested before they are published on your live site using a sandbox dashboard.

You should only send pageviews to a production dashboard for URLs that appear on your live site, or that you want to appear in your dashboard and API results. Creating a separate sandbox dashboard to track staging pages is a better approach.

Troubleshooting Staging/Development Tracking Issues

Seeing posts in the dashboard associated with staging/development URLs is likely a result of tracking code on a staging/development site with the Site ID set to your production site. If the tracking code is already integrated this way on your staging/development site but you would like to remove the staging/development post pages from Dash, please contact your account representative or They can help block the reception of pageview and heartbeat events from specific subdomains such as your staging/ development site.

Another common source of data inconsistency occurs when publishers fire pageviews from a staging/dev site to a production dashboard with URLs for articles that haven’t yet been published. For example, the page fires a pageview for the URL (the URL on the production site, which has yet to go live).

After blocking the reception of additional events from your staging/development site, we will attempt to remove the posts associated with staging/development sites from our records, and then update the traffic data in the dashboard to reflect the changes.

Last updated: December 02, 2022