Enabling debug mode for experiments
Learn how to activate Pertento’s debug mode using the console or local storage to inspect experiment behavior and troubleshoot activation during development.
1 min read
Pertento includes a debug mode that helps developers and QA teams inspect experiment behavior, variant assignment and activation details during testing. Debug mode does not affect live traffic and is only active in your local browser.
You can enable it in two ways.
Enable debug mode via console
Open your browser’s Developer Tools and run:localStorage.setItem('PERTENTO_DEBUG', 'true');
Reload the page and Pertento will run in debug mode.
Enable debug mode via local storage
You can also enable debug mode manually:
- 1Open Developer Tools
- 2Go to the Application tab
- 3Open Local Storage
- 4Select your domain
- 5Add or edit the key:
PERTENTO_DEBUG = true
Reload the page.
What debug mode does
Debug mode provides enhanced visibility into:
- experiment assignments
- variant activation
- targeting evaluation
- script loading behavior
- reporting calls
This information is visible through the browser console.
Notes
- Debug mode only affects your browser session.
- It should not be used in production environments for end users.
- Remove the key or set it to false to disable debug mode.