robots.txt

robots.txt is a plain-text file at a website's root that tells search engine crawlers which URLs or sections of the site they may and may not request.

Last updated: June 9, 2026

robots.txt follows the Robots Exclusion Protocol, using simple Allow and Disallow rules to steer crawler behavior. It's a request rather than a lock, but reputable crawlers like Googlebot respect it, which makes it a standard way to manage how a site gets crawled.

A Shopify store often disallows internal search and cart URLs so crawlers spend their time on real product and collection pages, and it usually links to the XML sitemap as well. One important catch: robots.txt controls crawling, not indexing, so it isn't a way to hide a page from results. A URL blocked here can still appear in search if it's linked elsewhere; to keep a page out, use a noindex tag instead.

Used with care, robots.txt protects crawl budget by keeping bots away from low-value or duplicate URLs and pointing them at the content you actually want found.

Related terms

Share this Story