Documentation

General / Html – Robots.txt

Posted in: Getting Started (4) How To (17) Plugin Options Explained (42) Actions / Filters (35)   

Replace Default Admin URLs within Robots.txt

The robots.txt file helps search engine crawlers understand which areas of your website should or should not be crawled. If no physical robots.txt file exists, WordPress automatically generates one dynamically, including references to the default administration area.

By default, the generated robots.txt contains directives similar to:

User-agent: *
Disallow: /wp-admin/
Allow: /run-ajax.php

While these entries are harmless for a standard WordPress installation, they become undesirable once the WP Hide plugin has customized the administration URL. Replacing the default paths with your new admin URL would unnecessarily disclose the location of your protected login area.

How WP Hide protects your customized admin URL

When Replace Default Admin URLs within Robots.txt is enabled, WP Hide intercepts the dynamically generated robots.txt output and replaces any references to the default WordPress administration paths with randomly generated values.

For example, instead of exposing either the default or the customized admin URL, the output may become:

User-agent: *
Disallow: /k8fd92lm/
Allow: /k8fd92lm/run-ajax.php

The random values do not correspond to any valid location on your website. Their sole purpose is to prevent revealing either:

  • the default WordPress administration paths (/wp-admin/ and run-ajax.php), or
  • your customized administration URL configured through WP Hide.

This ensures that the robots.txt file cannot be used as an information source to discover your site’s administration endpoint.

Why not use the customized admin URL?

Although search engines generally respect the directives contained in robots.txt, the file is publicly accessible by anyone. Publishing the customized administration URL would expose the very location that WP Hide is designed to protect.

Instead of substituting the default paths with your new admin URL, WP Hide replaces them with random values, ensuring that no meaningful information about your administration area is disclosed.

Example

Default WordPress output

User-agent: *
Disallow: /wp-admin/
Allow: /run-ajax.php

With WP Hide enabled

User-agent: *
Disallow: /x7m2qf9k/
Allow: /x7m2qf9k/run-ajax.php

The random values are generated automatically and may change over time. They do not represent actual URLs on your website.

Sample URL

https://your-domain.com/robots.txt

Enabling this option provides an additional layer of information hiding by ensuring that your robots.txt file cannot reveal the location of your customized WordPress administration area.

 

Share on FacebookShare on Google+Tweet about this on TwitterShare on LinkedIn
Scroll to top