How to see AI bot traffic on WordPress
Jetpack Stats, Site Kit and Google Analytics count visits that run JavaScript. AI bots do not: they request the page, read the text and leave. To see them you have to look at the requests that reach the server.
Where bot visits are recorded
Every request goes through your host's server, which writes an access log with each visit's user agent. On cPanel hosts (Bluehost, HostGator, Hostinger, SiteGround and others) it is under Metrics > Raw Access. That is where names like GPTBot, ChatGPT-User, ClaudeBot and PerplexityBot show up.
Reading that file by hand works for a quick look, but it will not tell you whether a bot is genuine, or group the visits by agent and by page.
Option 1: from your host's log (no change to the site)
Works on any cPanel host and does not touch WordPress. A small script runs every 5 minutes from cPanel's Cron Jobs and sends the new log lines.
- Create the free Knocklog project with your site's address and pick cPanel.
- In File Manager, create a knocklog folder outside public_html and upload the file Knocklog generates, which already holds your key.
- In Cron Jobs, schedule the command shown to run once every five minutes.
Some hosts only release the processed log, once a day. On those, visits arrive with that delay.
Option 2: with a PHP file (visits as they happen)
A PHP file loaded before WordPress records each request as it arrives, including the signatures some agents send.
<?php
require_once __DIR__ . '/knocklog.php';
// ...the rest of wp-config.php stays the sameSave the knocklog.php file Knocklog generates in the wp-config.php folder and add the line above right after <?php. If the site uses a page cache (LiteSpeed Cache, WP Rocket, WP Super Cache), cached pages never reach PHP: use Option 1 as well.
What you get to see
- Which AI agents read the site and which pages each one read.
- Which were genuine and which used someone else's name.
- How many people ChatGPT, Claude and Perplexity sent, and which became leads.
- What your robots.txt allows or blocks for each agent.
See how your WordPress site treats AI agents
The check is free and needs no sign-up.
Sources
Read next
- Knocklog vs Cloudflare AI Crawl Control vs Known Agents
- How to block AI training without disappearing from ChatGPT
- What is llms.txt and how to create yours
- An RB2B alternative that also sees the AI agents
- GPTBot vs ChatGPT-User vs OAI-SearchBot: what each OpenAI bot does
- How to see ChatGPT traffic in Google Analytics 4
- How to see which AI agents visit my website
- Directory of AI agents