See your website's visit statistics (AWStats, logs)
To find out how many people visit your site, which pages they read and where they come from, cPanel provides statistics screens, including AWStats. This article explains which one to open depending on your need, including how to get the raw logs.
Before you start
- You can access cPanel (see the article "Log in to cPanel").
- Your site must have received visits. A brand-new site shows almost nothing.
- Statistics screens are enabled by the host: if one is missing in your cPanel, it is not available on your account.
Steps: open AWStats
- Open the statistics section. On the cPanel home page, look for the "Metrics" section, or type "AWStats" in the search box at the top of the page.
- Click AWStats (written Awstats in the cPanel documentation).
- Click "View" next to the domain you are interested in.
- Read the sections. According to the cPanel documentation, AWStats shows, for that domain, monthly, daily and hourly averages in graphs and tables, the links through which visitors arrive, HTTP codes, operating systems, browsers and countries of origin. The colour of a graph item matches the header whose data it represents.
Which screen for which need?
| You want… | Open |
|---|---|
| An overview of traffic (graphs, averages) | AWStats |
| See the latest visits one by one | Visitors (Visiteurs) |
| Spot missing pages or server errors | Errors (Erreurs) |
| Download the full log to analyse it with another tool | Raw Access (Accès brut) |
Visitors. Click the magnifying glass next to the domain. By default the screen shows the IP address, the requested URL, the time, the size in bytes, the referring address and the browser. The gear icon adds the HTTP status, the method (GET, POST…) and the protocol version. The Search box filters the lines. If the host rotates the logs, the screen shows fewer entries.
Errors. The screen shows up to 300 of the most recent entries of the web server's error log, newest first. For older entries you have to go through the log files themselves.
Download (or keep) the raw logs
Access logs are compressed text files containing every visit. To get them, open Raw Access:
- Under Download Current Raw Access Logs, click the domain name or the download icon. You get a
.gzfile. - Open it with a decompression tool, then with a text editor or a log analysis tool.
- To keep your logs longer, tick "Archive log files in your home directory after the system processes statistics" under Configure Logs: files are then archived in the
logsfolder of your space. You can also ask for the previous month's archives to be deleted automatically or set a retention period; by default retention is unlimited. Click Save.
Expected result
You see your site's number of visits, pages and sources, or a downloaded .gz file containing one line per request.
If something goes wrong
- Statistics are empty or behind. According to the cPanel documentation, the system processes statistics every 24 hours by default, and the server administrator can change that. Very recent visits are therefore not there yet.
- The domain is not in the list. Only the account's domains are listed; check the spelling and that the domain is added to your account.
- A statistics screen is missing. It is not enabled on your account; contact support.
- Figures look higher than expected. Visits also count search-engine robots and automated requests; logs record every request, including images and style files.
- You want statistics without cPanel access. Download the logs from Raw Access and analyse them with a tool of your choice, or install an audience measurement tool on the site.
Frequently asked questions
What is the difference between AWStats and Visitors? AWStats summarises: graphs, averages, browsers, countries. Visitors details the latest requests one by one.
Where are the logs stored?
Archives, if you enable them, are in the logs folder of your space, according to the cPanel documentation.
Are the statistics real time? Not for AWStats: they update at each processing run, every 24 hours by default. The Visitors screen reads the log directly.
What about Webalizer or Analog? They are other statistics tools that may appear next to AWStats if the host has enabled them; the screen is read the same way.
Going further
Need a hosting space with cPanel and its statistics? Discover our web hosting.