Writing nofollow in robots.txt actually does not take effect, which standards recognize which fields.

📅 2026-10-13 👁️ 14

Why does the nofollow directive in robots.txt not work, and what fields are defined in the robots exclusion protocol standard?The answer is straightforward: there is no such instruction as nofollow in standard text. According to the standard, the robots exclusion protocol only has two groups of fields - User-agent statements specify which crawling program the rules apply to, and Disallow statements specify which paths are not allowed to enter.The 'nofollow' attribute is a meta tag instruction for web pages and does not belong to the file field of robots.txt. When written into a file, it will only be treated as an invalid line by standard parsing crawling programs.

Which fields are recognized in the standard

The standard text uses User-agent and Disallow to build the entire rule block: The file header declares which crawling program this set of rules is aimed at, and the following lines list the paths that are not allowed to enter. The rest of the writing cannot be found in this standard. When checking the problem of 'The rules are written but the crawler does not care', the first step is not to suspect the crawler, but to check whether the content is in the standard field list - the lines not in the list are as if they have not been written.

Which layer does nofollow belong to

Two nouns differ only by a suffix, but they belong to two different levels: robots.txt is a site-level crawling protocol, answering 'which paths should not be accessed'; webpage meta tags are document-level instructions, answering 'how to treat the pages already in hand'. nofollow belongs to the latter. Inserting the latter into the former is like putting an indoor notice on the community gate - in the wrong place, and the person reading it has no right to execute it.

Where to act to block crawling and to block inclusion

Do not be caught, configure robots: Fill in Disallow according to the path. Pay attention that only blocking crawling does not prevent indexing - the page may still be indexed due to external links, and displayed as a truncated abstract. If you want to completely exit the index, move the server: Confirm the old addresses that are offline and use 301 redirect to the replacement page, and clarify the address and weight destination; Directly close access to content that should not be made public. Both paths take care of one end, and using the opposite direction is equivalent to being busy for nothing.

Two common mistakes in on-site configuration

Firstly, after changing the pseudo-static rules, do not look back at robots: the path form has changed, and the rules written with the old path prefix in Disallow will be empty. Secondly, use robots.txt as an inclusion switch: it controls whether to enter or not, not whether to include or not. The AnQiCMS backend has made the Robots.txt configuration and 301 redirect management into two independent entries, which is designed according to these two lines - rules that should not be crawled should be written, and those that should not be indexed should be redirected or access closed.

Common questions

Question: If there is a nofollow line in the previous file, will there be any problems immediately?Answer: It won't happen immediately, but the standard parsing crawling program didn't execute this line at all. The effect you thought was effective has never been effective, and it is recommended to clean up and use the correct layer instead.

Question: If you want to temporarily prevent the column from being indexed, where should you start?Answer: First, judge whether it should be open to the outside: if it shouldn't be open to the outside, close the access and point the old link to the alternative page with 301; if you just don't want it to be indexed temporarily, use page-level control processing, don't force it into robots.txt.

Question: After adjusting the crawling rules, what is the order of checking?Answer: First, check if the new path prefix matches the existing Disallow entries; then follow the 301 redirect chain again to confirm there are no breakpoints; finally, check if the address has been switched to in the newly generated sitemap.

Related articles

How to read the 'remain' and 'not_valid' fields after submitting the link to Baidu's push interface

According to Baidu Search Resource Platform documentation, when the API push is successful, it returns the four fields: success, remain, not_same_site, and not_valid: remain is the remaining quota for the day, and not_valid is the list of invalid links; when it fails, it returns client error codes starting with 4 or a 500 server error code. This article discusses the troubleshooting order by field and explains which part of the link push and sitemap covers the link inclusion path.

2026-10-13

The page engine for the newly published page is taking a long time to crawl, which part does the sitemap and IndexNow manage?

New pages are not indexed in time, first distinguish which part of the site map and IndexNow are responsible for the indexing chain: The site map provides a complete list and tells the engine what is on the site; IndexNow and similar real-time notification mechanisms are responsible for informing participating engines of content changes as soon as possible. Both complement each other, and full and incremental two chains need to be configured in the site to ensure the timeliness of indexing.

2026-10-13

What is the single file limit of the site map, and how to split it into index files when the URL exceeds ten thousand?

The number of entries and the volume limit of a single sitemap file are agreed upon by the protocol. When approaching or exceeding the limit, the file should be split into multiple sub-files and grouped using an index file, organized by category and update time. This article explains the limit from the sitemap protocol, how to split when exceeding the limit, and the method of supplementing the collection时效 through active push after splitting.

2026-10-13

What should be prepared in advance for port and data backup when deploying the enterprise website with Docker?

Before the enterprise website is deployed with Docker, it is necessary to plan the two things of port mapping and data backup in advance. The system provides the official image, listens to the default port 8001, and needs to clarify the internal and external port mapping and access entry before going online; at the same time, the backup capability covers data and static files, which can be restored to avoid the loss of content after the container is rebuilt.

2026-10-13

What are the conventions of Disallow, asterisk, and dollar sign in robots.txt?

The two basic instructions of robots.txt are Allow and Disallow, which respectively indicate allowing or prohibiting the crawling of certain paths; the asterisk is a wildcard that can match any character sequence, and the dollar sign at the end of the line indicates that the address ends exactly at this point. This format is standardized by RFC 9309. It should be noted that it only constrains crawling behavior, does not determine whether a page can be included, and is not effective for all robots; after changing the pseudo-static rules within the site, the robots configuration needs to be reviewed to ensure that the match is still valid.

2026-10-13

The page has been changed, but the user still sees the old version. What order should be followed from clearing the cache to verification?

The content has changed, but the front-end is still showing the old page. Most of the time, it's not that the program hasn't taken effect, but rather that the intermediate cache layer is still hitting the old copy. Investigate in three steps: first, prove false on the source station and confirm that the change has really been saved to the database; then clear the cache at an appropriate granularity, with edge nodes supporting a variety of ranges such as address, domain name, tag, prefix, and the entire site; finally, check whether the cache status header in the response has changed from a hit to a source, and confirm that there is no trace of verification through the user side. Make a backup before making batch changes and keep a fallback.

2026-10-13

After the site-wide replacement changes the column name, should the anchor text and pseudo-static rules follow?

The site-wide replacement can change keywords and links in the main text in one go, but it only covers the content text layer: column names and address forms belong to the structure and routing layer. After the change, the keywords in the anchor text library and the matching paths of the static rules may not match the new address. At the end, three things need to be done - check the anchor text distribution range, review the static rules, and check the jump between new and old addresses to prevent broken links left by batch changes. Back up before changing, and keep a fallback ready.

2026-10-13

The content has not changed and the page is still slow, check the max-age and s-maxage of the cache headers first.

When the content is not changed but the page loads slowly, the order of checking the cache control header is to first see which layer the instruction acts on: max-age controls the freshness seconds of the browser's private cache, s-maxage controls the shared cache of CDN and will override max-age, no-store makes any cache not store. This article gives the binary method of transport layer and rendering layer, as well as the checking actions of each layer: browser, shared cache, and origin server.

2026-10-13