Server environment variables
Configure the server using environment variables when starting the application.Required variables
The port number the server listens on.
Choose a port that doesn’t conflict with other services on your system.
Authentication token for dashboard APIs. Required for accessing tracking data.
Optional variables
Path to the SQLite database file.
The directory must exist and be writable. The database file will be created automatically if it doesn’t exist.
Deduplication window in milliseconds. Open events within this window from the same source are marked as duplicates.This prevents counting multiple opens from email client prefetching or automatic reloads. Default is 30 seconds (30000ms).
Example configurations
Extension configuration
Configure the Chrome extension through its popup interface.Extension popup settings
Access settings by clicking the Email Tracker extension icon in your Chrome toolbar.Tracker Base URL
The URL of your tracking server:- Local development:
http://localhost:8090 - Production: Your HTTPS domain (e.g.,
https://tracker.yourdomain.com)
Dashboard Token
Must match theDASHBOARD_TOKEN environment variable set on your server. This authenticates API requests from the extension to the dashboard.
If you change the token on the server, you must also update it in the extension popup.
Extension storage
The extension stores configuration and tracking state in Chrome’s local storage:- Tracker Base URL
- Dashboard Token
- User ID (generated on first use, stable per Chrome profile)
- Recent email tracking data
Self-hosting configuration checklist
If you’re self-hosting Email Tracker, ensure you configure:HTTPS reverse proxy
Configure a reverse proxy (Caddy or Nginx) for production email client compatibility.Sample configurations available in:
deploy/Caddyfiledeploy/nginx-email-tracker.conf
Strong DASHBOARD_TOKEN
Generate a strong, random token for dashboard authentication.Example generation:
Production recommendations
Security
- Keep
DASHBOARD_TOKENprivate and secure - Use HTTPS for all production deployments
- Store environment variables in secure configuration management
- Never commit tokens or secrets to version control
Reliability
- Run the server with a process manager (
systemdorpm2) - Monitor server health and disk usage
- Set up automatic restarts on failure
Data management
- Back up the SQLite database file regularly
- Rotate logs and monitor disk usage
- Set up automated database backups
Monitoring
Consider monitoring:- Server uptime and health endpoint (
/health) - Database size and growth
- API response times
- Error rates in logs
Environment-specific configurations
Development
http://localhost:8090
Staging
https://tracker-staging.yourdomain.com
Production
https://tracker.yourdomain.com
Troubleshooting configuration issues
Extension can’t connect to server
- Verify the Tracker Base URL matches your server URL exactly
- Check that the server is running and accessible
- Ensure HTTPS is used in production
- Check browser console for connection errors
Dashboard authentication fails
- Verify
DASHBOARD_TOKENmatches between server and extension - Check that the token has no leading/trailing whitespace
- Restart the server after changing environment variables
Tracking pixels not loading
- Confirm HTTPS is used in production (required by most email clients)
- Verify the server is accessible from the internet
- Check firewall and DNS configuration
- Test the pixel endpoint directly:
curl https://your-domain/t/test.gif
Next steps
- Review the quickstart guide for testing your configuration
- Learn about installation options for deployment
- Set up monitoring and backups for production use