Robots.txt Generator
Draft robots.txt crawler rules from paths, presets and sitemap entries; review before publishing.
User-agent: *
Disallow:
Sitemap: https://example.com/sitemap.xml
About the Robots.txt Generator
Generate a single crawler group with User-agent, Allow/Disallow paths, optional Crawl-delay and one or more Sitemap lines. Blank paths are skipped, nonblank paths get a leading slash, and no path rules produces an empty Disallow line.
Presets change the fields; selecting Custom retains their current values rather than clearing them. User-agent selects a crawler, Allow/Disallow express crawl paths, and Sitemap lists a discovery URL. This tool formats entered strings; it does not verify crawler support, sitemap existence or your site's effective crawl policy.
robots.txt is public crawl guidance, not password protection or a guarantee that a URL disappears from search. A crawler needs access to read a page's noindex directive, so blocking that page can prevent discovering the directive. Copy the reviewed output and separately publish it at your own origin's /robots.txt.
Key features
- Presets for common setups
- Allow and disallow rules per path
- Optional crawl-delay and sitemap
- Copy-ready draft for independent review
How to use
- 1Pick a preset or Custom and inspect the retained fields.
- 2Enter paths, a crawler name and full sitemap URLs; review the generated group and confirm any optional Crawl-delay is supported by your intended crawler.
- 3Back up your current file, publish reviewed text at /robots.txt on the correct origin, then verify the served file and affected crawl rules. This page does not deploy it.
Examples
Allow all; sitemap https://example.com/sitemap.xmlUser-agent: * and Sitemap directivesReview the generated rules before publishing them at /robots.txt.
User-agent *; Disallow wp-admin/; Allow wp-admin/admin-ajax.php; Sitemap https://example.com/sitemap.xmlUser-agent: *
Allow: /wp-admin/admin-ajax.php
Disallow: /wp-admin/
Sitemap: https://example.com/sitemap.xml
Generated syntax only; review against your own paths and crawler behavior.
Frequently asked questions
- Where do I put the robots.txt file?
- Save it as robots.txt in the root of your domain, so it is served at https://yourdomain.com/robots.txt.
- Does Disallow hide a page from Google?
- No. A blocked URL can still be indexed from other signals. A crawler must be able to fetch a page to read its noindex directive; do not block that fetch if you rely on noindex.
- Should I add my sitemap?
- Yes. Listing your sitemap URL helps search engines discover all of your pages more efficiently.
- Does this validate my sitemap or block access to private pages?
- No. Sitemap entries are formatted strings, and crawler rules are not authentication. Protect private content with appropriate access controls.
Continue your workflow
Open a related tool to prepare your files or refine the finished result.
- Web & SEOJSON-LD Schema Generator
Draft five JSON-LD entity templates for review against your actual page content.
Open tool - Web & SEOMeta Tag & Open Graph Generator
Generate SEO, Open Graph and Twitter meta tags with a live social preview.
Open tool - Web & SEOGoogle SERP Snippet Preview
Preview how your title and meta description appear in Google search results.
Open tool
