1. Home
  2. Website
  3. How to access my website stats without logging into cPanel?

How to access my website stats without logging into cPanel?

This access your website statistics (AWStats) without login into article provides you with steps to cPanel. Please note that these steps are for advanced users who know cPanel folder structure.

What is AWStats? 

AWStats is a free powerful and featureful tool that generates advanced web, streaming, FTP or mail server statistics, graphically. This tool is available on all our cPanel and WSP packages.

 

 

How to access AWStats without logging into cPanel?

 

  • Get yourself a copy of AwStats from http://awstats.sourceforge.net. The latest version available at the time of this writing is AWStats 7.8.
  • Extract the content from the archive to your hard drive.
  • Using an FTP client, create a directory at the root of your website (ie.: /public_html) and name it “stats” (or whatever you’d like to call it). At this point, your directory should be accessible like this: http://www.yourwebsite.com/stats
  • Next upload the content from AWStats-6.7www.rootcgi-bin to your stats directory you’ve just created.
  • Using your FTP client, change the file permissions on awredir.pl and awstats.pl to 755 so that anyone can execute these scripts.
  • Still using FTP, download the AwStats configuration file created by cPanel to your computer. This file is usually located in /tmp/awstats/awstats.[your website].conf
  • Upload this file back to your web hosting account in your /public_html/stats folder.
  • Create a directory named images in /public_html (ie.: /public_html/images).
  • Upload the AwStats icon folder (ie.: AWStats-6.7/wwwroot/icon) to your images folder you’ve just created. Rename the icon folder to AWStats (ie.: /public_html/images/awstats).

 

 

At this point, you should now be able to access AWStats with this URL: http://www.yourwebsite.com/stats/awstats.pl?config=yourwebsite.com

But we’re not done yet. We don’t want everybody to access our statistics!

 

Note for WordPress users: password-protecting a subdirectory will not work because of the redirections instructions in the .htaccess file at the root of your website. While it’s not impossible to make it work, it’s easier to create a subdomain for AWStats (ie.: http://stats.yourwebsite.com).

Ok great we can now access AwStats outside cPanel. But we can make things even easier. How about accessing your stats at http://www.yourwebsite.com/stats and not having to specify the configuration file?

  • Using Notepad, create a file named index.php on your computer and add the following content:
<?php
header('Location: http://www.yoursite.com/stats/awstats.pl?
config=yoursite.com');
?>
  • Upload this file in your stats folder (ie.: /public_html/stats)

 

Now try to open http://www.yourwebsite.com/stats with your web browser. You should now be prompted for a username and password. You will then be redirected automatically to your statistics page!

 

 

Updated on March 6, 2023

Was this article helpful?

Related Articles