Pageviews
Understanding how Ghost Metrics tracks pageviews automatically.
Automatic Tracking
When you install the Ghost Metrics tracking code, pageviews are tracked automatically. Every time a visitor loads a page, data is captured and sent to your dashboard — no additional configuration required.
What’s Captured
For each pageview, Ghost Metrics automatically records:
Page Information
- Page URL — The full URL of the page visited
- Page Title — The HTML
<title>of the page - Referrer — The previous page or external source
Visitor Information
- Browser — Chrome, Firefox, Safari, Edge, etc.
- Operating System — Windows, macOS, iOS, Android, etc.
- Device Type — Desktop, mobile, or tablet
- Screen Resolution — Visitor’s screen size
- Language — Browser language setting
Location
- Country — Determined from IP address
- Region — State or province (when available)
- City — Approximate city (when available)
IP addresses are anonymized and not stored in their complete form.
Timing
- Timestamp — When the page was viewed
- Time on Page — How long the visitor spent on each page
- Generation Time — How long the page took to load
Viewing Pageview Data
Find your pageview data in several reports:
Behavior → Pages
All pages ranked by pageviews. See:
- Total pageviews
- Unique pageviews
- Average time on page
- Bounce rate
- Exit rate
Behavior → Entry Pages
The first page visitors see when they arrive at your site. Useful for understanding which pages attract new visitors.
Behavior → Exit Pages
The last page visitors see before leaving. High exit rates on important pages may indicate problems.
Behavior → Page Titles
Pages grouped by their HTML title rather than URL. Helpful when URLs are complex or dynamic.
Custom Page Titles
By default, Ghost Metrics uses your page’s HTML <title> tag. You can override this if needed:
_mtm.push({'event': 'setDocumentTitle', 'title': 'Custom Page Title'});This is useful when:
- Page titles are dynamically generated and unhelpful
- You want to group similar pages under one title
- Your CMS produces duplicate or generic titles
Virtual Pageviews
For single-page applications or AJAX-loaded content, you may need to manually track pageviews when the URL changes without a full page reload:
// Track a virtual pageview
_mtm.push({'event': 'trackPageView'});If the URL has changed, update it first:
_mtm.push({'event': 'setCustomUrl', 'url': '/new/page/path'});
_mtm.push({'event': 'trackPageView'});Excluding Pages from Tracking
There may be pages you don’t want to track, such as admin areas or internal tools.
Option 1: Don’t Install Tracking Code
Simply don’t include the tracking code on pages you want to exclude.
Option 2: Conditional Loading
Use server-side logic to conditionally include the tracking code:
<?php if (!is_admin_page()): ?>
<!-- Ghost Metrics tracking code here -->
<?php endif; ?>Option 3: Exclude in Ghost Metrics
You can configure URL exclusions in your Ghost Metrics settings. Contact support for help setting this up.
Understanding Metrics
Pageviews vs Unique Pageviews
- Pageviews — Total number of times a page was viewed (including repeat views in a single session)
- Unique Pageviews — Number of sessions that included a view of that page
Bounce Rate
The percentage of visits where the visitor left after viewing only one page. A “bounce” means they didn’t interact further with your site.
Exit Rate
The percentage of pageviews that were the last in a session. Unlike bounce rate, this includes visits with multiple pageviews.
Average Time on Page
How long visitors typically spend viewing a page before navigating away or leaving the site.
Next Steps
- Track custom events — Measure specific user interactions
- Set up goals — Track conversions
- View behavior reports — Analyze page performance