Robots.txt Generator
Build your robots.txt visually — set rules per bot, add sitemaps, crawl-delay & more. Live preview.
Directive Reference — What each field means
| Directive | Syntax | Description |
|---|---|---|
| User-agent | User-agent: * | Specifies which crawler the following rules apply to. Use * for all bots. Repeat for multiple bots. |
| Allow | Allow: /path/ | Explicitly permits crawling a path, even within a Disallowed directory. More specific rules take precedence. |
| Disallow | Disallow: /path/ | Tells bots not to crawl the specified path or directory. An empty value means "allow everything". |
| Sitemap | Sitemap: https://…/sitemap.xml | Points crawlers to your XML sitemap. Can appear multiple times for multiple sitemaps. |
| Crawl-delay | Crawl-delay: 10 | Asks bots to wait N seconds between requests. Honoured by Bing, Yandex — not Googlebot. |
| Host | Host: https://example.com | Preferred domain declaration, mainly used by Yandex to resolve mirror conflicts. |
Path matching:/page matches only that page. /dir/ matches the directory and everything inside. A trailing * is a wildcard. $ matches end of URL.
Build a valid robots.txt file by picking user-agents, toggling Allow/Disallow rules, and adding sitemaps — all from a visual interface instead of editing raw text. The output updates live so you can spot mistakes before uploading anything. And everything runs in your browser. Nothing gets uploaded.
How It Works
Select which crawlers you want to target — Googlebot, Bingbot, or all bots at once. Add Allow and Disallow rules for specific paths, then drop in your sitemap URL. The generator builds the file live as you configure. When it looks right, copy the text or download the file and upload it to your site root.
Examples
Block all bots from admin pages
You have a WordPress site and want crawlers away from /wp-admin/ and /wp-login.php.
User-agent: *
Disallow: /wp-admin/
Disallow: /wp-login.php
User-agent: *
Disallow: /wp-admin/
Disallow: /wp-login.php
Sitemap: https://example.com/sitemap.xml
Allow Google but block everything else
A client wants only Google to index their site during a soft launch. Everyone else gets locked out.
User-agent: Googlebot
Allow: /
User-agent: *
Disallow: /
User-agent: Googlebot
Allow: /
User-agent: *
Disallow: /
Sitemap: https://example.com/sitemap.xml
E-commerce site with filtered pages blocked
An online store has thousands of duplicate filter URLs like /products?color=red&size=xl that waste crawl budget. The actual product pages should stay indexed.
User-agent: *
Allow: /products/
Disallow: /products?
Disallow: /cart/
Disallow: /checkout/
Disallow: /account/
User-agent: *
Allow: /products/
Disallow: /products?
Disallow: /cart/
Disallow: /checkout/
Disallow: /account/
Sitemap: https://store.com/sitemap.xml
Sitemap: https://store.com/products-sitemap.xml
Who Uses This
Generating robots.txt during site deployment so staging paths and API endpoints stay out of search indexes.
Controlling crawl budget by blocking faceted navigation, internal search results, and duplicate parameter URLs.
Keeping cart, checkout, and account pages out of Google while making sure product pages get crawled.
Blocking draft folders and media upload directories from being indexed before content goes live.
Common Mistakes
Crawlers only check the domain root — /robots.txt. A file at /pages/robots.txt or /blog/robots.txt does nothing. Upload it to the top-level directory of your domain.
robots.txt is publicly readable. Blocking /secret-docs/ actually tells the world that folder exists. Bad bots ignore robots.txt entirely. Use server-side authentication for anything private.
Google needs to render your pages to rank them properly. If you block /css/ or /js/, Googlebot can’t see your layout and may rank you lower. Only block paths you genuinely don’t want crawled.
Technical Details
- Processing: 100% client-side — nothing is sent to a server
- Browser Support: Chrome, Firefox, Safari, Edge
- Output Format: Plain text robots.txt file (UTF-8)
- Spec Followed: Robots Exclusion Protocol (RFC 9309)
Frequently Asked Questions
What is robots.txt and why do I need one?
It’s a small text file that sits at your domain root and tells search engine crawlers which parts of your site to skip. Without one, bots crawl everything — including admin panels, duplicate pages, and staging content you’d rather keep out of Google.
Does robots.txt stop pages from appearing in Google?
Not exactly. It stops Googlebot from crawling the page, but if other sites link to that URL, Google might still show it in results with a “No information is available for this page” note. To fully remove a page from search results, you need a noindex meta tag or an HTTP header — and the page must be crawlable for Google to see that tag.
How often do search engines check robots.txt?
Google caches your robots.txt and re-fetches it roughly once a day, sometimes less for smaller sites. If you make changes, it can take up to 24 hours for Googlebot to pick them up. You can force a refresh through Google Search Console’s robots.txt tester.
Can I use wildcards in robots.txt?
Yes — Google and Bing support * as a wildcard and $ to match end-of-URL. For example, Disallow: /*.pdf$ blocks all PDF files across your entire site. Not every bot supports wildcards though, so stick to simple path rules when targeting lesser-known crawlers.
What happens if my robots.txt has a syntax error?
Crawlers are surprisingly forgiving — they’ll skip lines they don’t understand and try to follow the rest. But a wrong directive can accidentally block your whole site. The classic mistake is Disallow: / under User-agent: * when you meant to block just one folder. Always test your file in Google Search Console before going live.