This is an explanation about how Discourse handles pageviews and how to interpret the “Site traffic” report.
Required user level: Administrator
What are pageviews in Discourse?
Pageviews in Discourse are counted as all requests for content by humans. This includes:
- Requests for lists of categories, topics, or posts
- The first load of a page
- Transitions between routes (e.g., moving from topics to the latest list)
This does not include:
- Traffic from crawlers and bots
- Discourse API requests
Discourse works to ensure that pageviews are only counted on initial page loads or significant route changes to avoid inflating the numbers.
In September 2024, we improved the way in which pageviews are tracked and counted. Here’s an explanation of what changed.
The site traffic report
To access the report:
- As an administrator, go to the Discourse dashboard
- Navigate to
discourse.example.com/admin/reports/site_traffic
Understanding the report categories
- Pageviews (logged in): Pageviews from users who are logged into your Discourse instance.
- Pageviews (anonymous): Pageviews from users who are not logged in but are using a web browser.
- Known crawlers: Pageviews from identified web crawlers or bots (e.g., search engine crawlers).
- Other traffic: This category includes various types of requests that don’t fall into the other three categories, including other crawlers.
The default report view hides the known crawlers and other traffic metrics, so that it aligns with the pageview metrics displayed elsewhere in the dashboard.
Note that only logged in and anonymous browsers count toward the pageview limits on hosted plans.
Reading the report
The report displays data in a stacked area chart format, which allows you to visualize the composition and trends of pageviews over time:
- The X-axis represents the date range
- The Y-axis shows the number of pageviews
- Each category is represented by a different color in the stacked areas according to the legend above the report
The stacked nature of the chart allows you to see:
- The total traffic for each day (the top of the entire stack)
- The proportion of each category within the total
- Trends over time for each category and the total
Above the chart, you’ll find a legend that matches colors to categories, helping you interpret the data.
Interacting with the chart
- Date range: You can adjust the date range using the date picker below the report.
- Hover for details: Hover over any point on the chart to see a tooltip with exact numbers for each category on that specific date.
- Filtering: Click on the items in the legend to show/hide each category, allowing you to focus on particular data sets.
If you’re not seeing expected results, click the Refresh Report button to load the latest data.
Using pageview data
Pageview data can be valuable for understanding site traffic and user engagement. Some ways to use this data include:
- Tracking overall site activity: Monitor total pageviews over time to see trends in site usage.
- Assessing user engagement: Compare logged-in vs. anonymous browser pageviews to understand how many of your visitors are registered users.
- Monitoring crawler activity: Keep an eye on known crawler pageviews to ensure your site is being properly indexed by search engines.
- Identifying unusual activity: Sudden spikes in any category could indicate viral content, potential issues, or attacks.