Fine-Tune Tracking Behavior

Advanced options for power users to customize exactly what and how customer data is tracked.

Tracking Options

Track Logged-Out Users

Track guests who haven’t created accounts:

  • Enabled by default
  • Uses anonymous session IDs
  • Links to account if they register later
  • Essential for full customer journey tracking

Track Admin Sessions

Include administrator browsing:

  • Disabled by default
  • Useful for testing
  • Can skew analytics if enabled
  • Recommended: Keep disabled

Track Bot Sessions

Include search engine bots:

  • Disabled by default
  • Bots detected automatically
  • Filters Google, Bing, others
  • Keep disabled for accurate analytics

Control how long cookies last:

  • Session Cookie: Until browser closes (default)
  • Customer ID: 30, 60, 90 days, or 1 year
  • Referral Cookie: 7, 14, 30, or 60 days

Longer duration = better returning customer tracking.
Shorter duration = better privacy.

Performance Settings

Tracking Frequency

How often data is sent:

  • Real-time: Every page load
  • Every 3 pages: Batch 3 page views
  • Every 5 pages: Batch 5 page views
  • Session end: When visitor leaves

Batching reduces server requests.

Data Cleanup Schedules

When to run cleanup:

  • Daily: 3:00 AM (default)
  • Weekly: Sunday 3:00 AM
  • Monthly: 1st of month

Choose low-traffic time.

Archive Old Sessions

Move old data to archive:

  • Sessions older than 90 days
  • Keeps main tables fast
  • Archived data still accessible
  • Can restore if needed

Excluded Pages

Don’t track certain pages:

  • Admin pages (already excluded)
  • Checkout pages (optional)
  • Thank you pages
  • Custom URLs

Add URLs one per line:

/admin/
/wp-admin/
/checkout/
/my-account/

Excluded User Roles

Don’t track specific roles:

  • Administrator (recommended)
  • Shop Manager
  • Editor
  • Custom roles

Select roles to exclude from dropdown.

Custom Event Tracking

Track custom actions:

  • Button clicks
  • Video plays
  • PDF downloads
  • Form submissions
  • Scroll depth

Use JavaScript API:

puredevsTrack('event', {
  action: 'video_play',
  video_id: 123,
  video_title: 'Product Demo'
});

JavaScript API

Developer tracking options:

Track Page View

puredevsTrack('pageview', {
  page_url: '/custom-page',
  page_title: 'Custom Title'
});

Track Custom Event

puredevsTrack('event', {
  category: 'engagement',
  action: 'button_click',
  label: 'cta_button'
});

Identify User

puredevsTrack('identify', {
  user_id: 123,
  email: 'customer@example.com'
});

Debug Mode

Enable for troubleshooting:

  • Console logs all tracking events
  • Shows what data is sent
  • Displays errors
  • Don’t enable in production

Enable at: Settings → Advanced → Debug Mode

Sampling Rate

Track percentage of visitors:

  • 100%: Track everyone (default)
  • 50%: Track half of visitors
  • 25%: Track quarter of visitors
  • 10%: Track 10% sample

Useful for very high-traffic sites to reduce load.

Best Practices

  • Keep bot filtering enabled
  • Exclude admin users
  • Use default cookie duration
  • Enable debug mode only for testing
  • Track logged-out users for full journey
  • Use custom events sparingly
  • Test changes on staging first