Introduction to the Traffic Log module

Traffic Log module is designed to provide finer control over the Traffic Log system. It's your silent site traffic watcher which you can use to find out what exactly is going on your site.

So, you can think of the Traffic Log as nothing more than a window into web requests to your WordPress site.

Why would you need the Traffic Log?

In everyday use, you wouldn't need the watcher to be active. It'll use resources that you otherwise don't need to use.

But, if you're concerned about a sudden performance drop, or feel that your site is subject to some sort of attack, you can enable it to get a more informed view on your traffic.

Please note that the Traffic Log doesn't use a lot of resources. But it will perform an database insert (write) on each page load. It's a tiny execution and not one that will impact your page loading.

Shield performs this database write at the very end of execution so any page loading for the visitor will complete 99.99% and then the database execution starts.

In this way there'll be no noticeable performance impact from it if, for example, your SQL server is having trouble at the time.

How to configure Traffic Log module

This module is accessible from within the main navigation menu > Config > Traffic and configuring it is very easy. You just need to enable it and then configure the following options based on your requirements:

  • Traffic log exclusions
  • Custom exclusions (optional)
  • Auto expiry cleaning

Once it's been configured, you can start using Traffic Log Viewer to review and monitor your site traffic logs.

Traffic Logging Options Explanations

Option: Traffic Log Exclusions

You can use this option to select request types that you don't want to be included in the traffic viewer. The following request types can be excluded:

  • "Simple" - any HTTP requests to your site that don't contain any data parameters in either GET/POST.
  • REST API
  • AJAX
  • Logged-in users
  • WP Cron
  • Search bots - supports Google, Bing, Yahoo!, Duck Duck Go, Yandex, Apple, Baidu
  • Uptime Monitoring Services (i.e. Status Cake, Pingdom, UptimeRobot)

If a request matches any exclusion rule, it will not show on the traffic viewer.

To find out how the Traffic Log Exclusions option works, read the article here.

Option: Custom Exclusions

You can use this option to exclude the logging of web requests you know to be legitimate

For each entry, if the text is present in either the User Agent or request Path, it will be excluded.

Take a new line for each entry. Please note that comparisons are case-insensitive.

To learn how to manually customize exclusions,  read the article here.

Option: Auto Expiry Cleaning

You can use this option to enable traffic log auto expiry.

Simply enter the maximum number of days you want and the Database cleanup will delete logs older than that number of days.

Traffic Rate Limiting

Helps you to put a stop to bots and visitors that abuse your website and your hosting resources.
Traffic rate limiting is where you restrict the number of requests a single visitor can make against your site, within a certain period of time.

For more information about the Traffic Rate Limiting, read this article here.