WhoKnew Shield™ | Physical robots.txt vs Virtual (Pro)

Skip to main content
Table of Contents
Print

Your site’s robots.txt can come from a physical file on the server or from WordPress (virtual). WhoKnew Shield Pro behaves differently in each case: with a virtual robots.txt the honeypot entry is added automatically; with a physical file the tab shows Manual Setup Required and you use Auto-Fix or add the line yourself. This article explains the difference, when each applies, what the plugin does in each case, and how to fix permission or cache issues so the entry is correct.

What Is Physical vs Virtual?

TypeWhat it meansHow the plugin detects it
Physical robots.txtA real file named robots.txt in your site root (e.g. same folder as wp-config.php), or in the parent directory or the server’s document root. The web server or WordPress may serve it when someone requests /robots.txt.The plugin checks several possible paths (WordPress root, parent directory, document root). If any of those files exist, it treats robots.txt as physical.
Virtual robots.txtNo physical file. WordPress generates the content when someone requests /robots.txt using its built-in rules and the robots_txt filter.If no file is found at the checked paths, the plugin treats it as virtual. The tab then shows Robots.txt Integration (Auto-Enabled).

What the Tab Shows

In WhoKnew Shield → Scraper Trap™, scroll to the blue Robots.txt Integration section (🤖 icon). The heading will say one of two things:

  • Robots.txt Integration (Auto-Enabled) — No physical file was found. WordPress serves a virtual robots.txt and the plugin adds the honeypot Disallow line automatically. The entry is included every time someone requests /robots.txt. You can optionally disable integration via the checkbox Disable robots.txt integration (not recommended).
  • Robots.txt Integration (Manual Setup Required) — A physical robots.txt file was detected. The tab shows a red notice: Physical robots.txt File Detected. You are told to click 🔧 Auto-Fix Robots.txt (Add Entry Now) to add the honeypot entry to the file, or to add the shown block manually. The exact block (comment, User-agent: *, and Disallow: /wp-admin/admin-ajax.php?action=YOUR_ACTION_NAME) is displayed in a code box.

How the Plugin Serves robots.txt

Regardless of physical or virtual, when a visitor or bot requests yoursite.com/robots.txt, the plugin can intercept that request and serve a response that includes the honeypot entry. So even if you have a physical file, the plugin reads it, removes any old WhoKnew Shield block, appends the current honeypot Disallow line, and sends that merged content. That way crawlers still see the correct entry. The difference is: with a virtual setup, there is no file on disk to update. With a physical file, the copy on disk is not updated until you click Auto-Fix (or edit the file yourself)—so Auto-Fix is useful to keep the file on disk in sync and to satisfy CDN or server caches that might read the file directly.

When Auto-Fix Works (and When It Doesn’t)

Auto-Fix Robots.txt (Add Entry Now) is only shown when a physical file is detected. When you click it, the plugin reads the current robots.txt content, adds or updates the honeypot block, and writes the result back to the file. That requires write permission:

ConditionResult
Physical file exists and is writableAuto-Fix writes the entry into the file. Success message: “Robots.txt updated successfully!” Cache clearing (WordPress, and popular cache plugins if present) runs. You may still need to clear CDN or server cache manually.
Physical file exists but is not writableAuto-Fix fails. The plugin reports that the file exists but is not writable and suggests checking file permissions. Add the honeypot block manually (FTP or file manager) using the exact block shown in the red notice.
No physical file; plugin will create oneThe plugin uses the WordPress root directory. That directory must be writable. If it isn’t, you’ll see that the directory is not writable and robots.txt could not be created. Create the file manually or fix directory permissions.
No physical file (virtual)Auto-Fix is not shown. The honeypot entry is added automatically when robots.txt is requested; nothing to “fix” on disk.

What the Entry Looks Like

The plugin adds a block that tells crawlers to avoid the honeypot URL. The format is the same for physical and virtual:

# WhoKnew Shield™ – Web Application Firewall (do not remove)
User-agent: *
Disallow: /wp-admin/admin-ajax.php?action=YOUR_ACTION_NAME

YOUR_ACTION_NAME is the current honeypot action name (shown in the tab under Advanced: Manage Honeypot Action Name). When you regenerate or set a custom action name, the plugin tries to update robots.txt automatically. If it can’t (e.g. physical file not writable), a message tells you to click Auto-Fix Robots.txt or Verify Robots.txt Entry manually.

Verify and View Full

🔍 Verify Robots.txt Entry — Fetches your site’s /robots.txt (with a cache-busting parameter) and opens a modal that shows the full content and whether the honeypot entry was found. Use it after Auto-Fix or after changing the action name to confirm the Disallow line is present. If the entry is missing, enable Scraper Trap, save settings, and try Auto-Fix again (physical) or reload (virtual).

📄 View Full Robots.txt — Opens yoursite.com/robots.txt in a new tab. If you don’t see the updated action name, do a hard refresh (Windows/Linux: Ctrl+Shift+R; Mac: Cmd+Shift+R) or check the file via FTP/file manager. If you use a CDN (e.g. Cloudflare) or server cache, clear it; the tab notes that changes typically propagate within about 5–10 minutes.

Why add the honeypot to robots.txt? Legitimate crawlers (Google, Bing) that respect robots.txt will skip the Disallow URL, which is good for SEO. Bad bots that ignore robots.txt often treat “forbidden” URLs as valuable, so they’re more likely to request the honeypot and get blocked. So the entry both protects SEO and helps attract the bots you want to trap.

Physical file not writable? Some hosts (e.g. HestiaCP, cPanel with strict permissions) protect the root or robots.txt. Even then, when someone requests /robots.txt, the plugin intercepts and serves the merged content (physical file content + honeypot), so crawlers still see the entry. To get the file on disk updated, use FTP or the host’s file manager to add the block manually, or ask the host to make the file writable so Auto-Fix can run.

Quick Reference

SituationWhat to do
Tab says Auto-EnabledNo action needed. Entry is added automatically. Use Verify or View Full to confirm.
Tab says Manual Setup RequiredClick Auto-Fix Robots.txt (Add Entry Now). If it fails (not writable), add the shown block to robots.txt via FTP or file manager, then click Verify.
You changed the honeypot action namePlugin tries to update robots.txt automatically. If you see a note that it couldn’t, click Auto-Fix (physical) or Verify. Then use Verify to confirm the new Disallow line.
Browser or CDN shows old contentHard refresh; clear CDN/server cache. Wait 5–10 minutes if needed. Verify fetches with cache-busting so you can confirm what the site is actually serving.

Need Help?

robots.txt and Scraper Trap (Pro) — Why Shield adds a Disallow line, Auto-Enabled vs Manual Setup, and the Verify / View Full buttons. Troubleshooting: Scraper Trap Not Blocking — Includes the robots.txt and SEO tip. First-Time Scraper Trap Setup Checklist — Enable, whitelist, test, robots.txt step. Caching and WhoKnew Shield — Cache clearing and compatibility.

Share