← Back to Testing and Troubleshooting
Testing
Test default, accept, and decline
Use three clean sessions: first load with no choice, Accept All, and Decline. Prove the banner, the signals, and the network.
Prepare a clean browser
- Use Incognito or a fresh profile.
- Disable ad blockers for this test. They can hide both trackers and the widget.
- Open DevTools → Application → Local Storage and delete
sitetrust_consentif it already exists. - Test the published URL, not an editor canvas.
Session 1 — default, no click
- Load the homepage. The banner should appear without scrolling.
- Do not click Accept or Decline.
- Confirm optional pixels are not completing collection requests (GA4, Meta, Ads, TikTok, LinkedIn, Hotjar, Clarity).
- In Console, paste the logger, reload, and confirm Consent Mode default with denied ads signals.
window.dataLayer = window.dataLayer || [];
var _push = window.dataLayer.push;
window.dataLayer.push = function() {
var args = arguments[0];
if (args && args[0] === 'consent') console.log('[Consent Mode]', args[1], args[2]);
return _push.apply(this, arguments);
}Necessary tools may load. That is expected. Chat, booking, and LeadConnector iframes must not load on this session.
Session 2 — Accept All
- New Incognito window.
- Click Accept All (or save with Analytics and Marketing on).
- Confirm Consent Mode update with granted signals for the categories you allowed.
- Confirm GA4 / Ads may load after that update, not before.
- Reload the same window. The banner should stay dismissed. The stored choice should replay. Trackers that were allowed may load on this second view.
Session 3 — Decline
- New Incognito window again. Do not reuse Session 2.
- Click Decline (or reject optional categories).
- Confirm Consent Mode update with denied ads and analytics signals.
- Navigate to a second page. Optional trackers must stay off. A decline that only works on the first page fails Run C.
- Reload. The decline must persist.
Then run Site Audit
Manual DevTools is the first proof. Site Audit is the recorded proof: Run A, Run B, and Run C. Run A is the 30-second pre-consent capture. Run B is post-accept. Run C is post-decline.
Pass bar
Default shows the banner and no optional hits. Accept updates signals and allows the chosen categories. Decline updates signals and keeps optional tags off on the next page too.
Need help?
Email wecare@sitetrust.com with your site URL and platform. One business day response, Monday through Friday.