Configure your crawler rules using the form below. The live output updates in real time, download your robots.txt or copy it directly into your site's root directory.
Configure rules on the left and click
Generate robots.txt
Start from a proven template, Standard SEO, WordPress, E-commerce or Block All. Or build from scratch with custom rules.
Add as many User-agent rules as needed. Choose which bots to allow or block and specify which paths they can or cannot access.
Reference your XML sitemap URLs and enable options like crawl delay. The live preview updates as you type.
Click Download to save robots.txt, then upload it to the root of your domain, e.g. https://yoursite.com/robots.txt
A robots.txt file is a text file at your site root that tells crawlers which parts of your site they may request. It lives at yoursite.com/robots.txt, and a robots.txt generator writes the rules for you so the syntax is right first time.
The rule everyone gets wrong: it controls crawling, not indexing. Disallow tells a crawler not to fetch a page. It does not tell Google to keep it out of search. A disallowed page can still rank if other sites link to it, and because Google cannot fetch it, it never sees the noindex tag that would actually remove it. Blocking is not hiding.
It is also only a request. Well-behaved crawlers obey it. Scrapers and email harvesters read it as a map of what you would rather they did not see.
Written by Chirag Arora, digital marketing consultant with 17+ years of hands-on SEO experience across 500+ projects. He designed this tool and the other 22 free tools on this site. Verify on LinkedIn.
| Crawler | Who runs it | What blocking it costs you |
|---|---|---|
| GPTBot | OpenAI, training | Your content stops feeding future ChatGPT models. Blocking does not remove what it already has |
| OAI-SearchBot | OpenAI, search | You disappear from ChatGPT search results. This is the one people block by accident |
| ClaudeBot | Anthropic | Same trade as GPTBot, for Claude |
| PerplexityBot | Perplexity | You lose citations from the engine that links out most generously |
| Google-Extended | Google, AI training | You opt out of Gemini training. Normal Google Search ranking is unaffected |
| CCBot | Common Crawl | An open dataset many models train on. Blocking it is broad and blunt |
There is a real decision here and it is not the same for everyone. A publisher protecting paid work has good reason to block training bots. A business that wants customers to find it through AI has the opposite interest, because blocking the crawler removes you from the answers. The trap is that training and search are different bots: block GPTBot and you leave training, block OAI-SearchBot and you vanish from ChatGPT search. Most people who block one meant the other. Google's robots.txt documentation covers the syntax, and you can check what a rule does in Search Console before you publish it.
Robots.txt is a polite request, not a security measure. Any bad actor can ignore it. Never rely on robots.txt to hide sensitive data. Use authentication and server-level access control for that.
Add a Sitemap: directive pointing to your XML sitemap. Even though you can submit it in Google Search Console, having it in robots.txt ensures every bot that visits discovers it automatically.
Use Google Search Console's robots.txt Tester to verify your rules before uploading. A single misplaced Disallow: / will block Google from indexing your entire site, always test first.
Two wildcards give the file real power, and both are easy to get wrong. The asterisk matches any run of characters, so Disallow: /*.pdf blocks paths that contain .pdf. The dollar sign anchors a rule to the end of a URL, so Disallow: /*.pdf$ blocks files that end in .pdf but leaves report.pdf?ref=x alone. Paths are case-sensitive, so /Admin/ and /admin/ are different rules. And robots.txt is only one of three controls that people mix up. Robots.txt manages crawling. The meta robots tag in a page's head manages indexing for that one page. The X-Robots-Tag HTTP header does the same job as meta robots but for files with no head to edit, like PDFs. If you need a page kept out of the index, use noindex, not a Disallow, because a blocked page can never be crawled to see the noindex in the first place.
The robots.txt file sits at the root of your domain and uses the Robots Exclusion Protocol to tell compliant web crawlers which pages they are allowed or not allowed to access. Search engine bots like Googlebot, Bingbot and others check this file before crawling your site. Common uses include blocking admin pages, preventing duplicate content indexing, saving crawl budget on large sites and referencing XML sitemaps. Remember, it controls crawling, not indexing, a page can still appear in search results if other pages link to it, even if it's disallowed.
This free robots txt file generator builds the file for you online and previews the exact text before you upload it. Pick your platform, choose what to block, decide how to treat AI crawlers and copy the result. It runs in the browser with no account and nothing to install, and it works for any website whether that is WordPress, Blogger, Shopify or hand-built HTML.
Robots.txt is the smallest file on your site and the one that does the most damage when it is wrong. Across 500+ projects I have seen a single stray Disallow: / survive a staging launch and quietly remove an entire site from Google. Nobody noticed for six weeks. It is four characters. That is why this tool previews the file rather than just handing you a download, you should read the thing before it goes live.
The newer decision is what to do about AI crawlers, and most generators still pretend they do not exist. This one includes GPTBot, ClaudeBot, Google-Extended and the rest, because whether you want your content feeding AI answers is now a real business question rather than a technical footnote. Once the file is live, generate your sitemap with the free sitemap generator and add it as the last line, then check whether AI actually mentions you with the free AI visibility checker. The rest are in the free SEO tools hub.
One distinction saves people from a classic mistake. This file controls crawling, not indexing, so blocking a page here does not remove it from Google, a disallowed URL can still sit in results with no snippet. To keep a page out of the index you use a noindex meta tag or an X-Robots-Tag header, and the page has to stay crawlable for Google to see that instruction. Google stopped honouring a Noindex line inside robots.txt back in 2019, so it does nothing here. The file itself follows the RFC 9309 standard, must return a 200 status, and stays under 500 kilobytes for Google. And never list private paths as a way to hide them, that just hands attackers a map, protect those with real access controls instead.
Discover thousands of keyword ideas with volume, difficulty, CPC and intent data, powered by Google Autocomplete.
Launch ToolGenerate perfectly optimised title tags, meta descriptions, Open Graph and Twitter Cards in seconds.
Launch ToolMeasure Core Web Vitals, LCP, INP, CLS, with prioritised recommendations to fix every issue.
Launch ToolCommon questions about this free tool, answered clearly.
No. This trips a lot of people up. Robots.txt controls crawling, not indexing. A blocked page can still appear in Google if other pages link to it. To keep a page out of the index, use a noindex tag instead.
It must sit at the root of your domain, at yoursite.com slash robots.txt. Search engines only look there. A robots.txt in a subfolder is ignored.
Only if you do not want your content used or cited by AI tools. Blocking crawlers like GPTBot or Google-Extended removes you from those answers. If you want AI visibility, allow them and block only private areas.
WordPress serves a virtual robots.txt automatically, and Yoast or Rank Math let you edit it from the dashboard, so you may not need a file at all. Blogger has a custom robots.txt setting in Search Settings. Use this generator to write the rules correctly, then paste them into whichever box your platform gives you. The syntax is the same everywhere. What differs is where you put it.
It depends on what you sell, and the honest answer is that most people get this backwards. If you publish content people pay for, blocking training bots is reasonable. If you want customers to find you through AI, blocking the crawler removes you from the answers, which is the opposite of what you wanted. The critical detail is that training and search are separate bots. GPTBot is training, OAI-SearchBot is ChatGPT search. Block GPTBot and you keep your ChatGPT visibility. Block OAI-SearchBot and you disappear from it.
For writing the file, they do the same job. The difference is that this one includes current AI crawlers such as GPTBot, OAI-SearchBot, ClaudeBot and Google-Extended, and it previews the exact file before you copy it. Most robots.txt generators were written before AI crawlers existed and have not been updated. Beyond that there is not much to choose between them, because it is a text file.
This free tool writes the file. If you would rather have someone check it is not quietly costing you traffic, here are a few honest reasons businesses hire me as their SEO and digital marketing consultant in India.
Disallow: / on a live site removes it from Google. I have found it surviving a staging launch for six weeks while everyone blamed the algorithm. I check the boring file first.
I started as a technical SEO trainee, not in a management seat, and I still write the robots and crawl rules myself. You get direct expertise, not a ticket passed to a developer.
The robots.txt generator you just used, I designed it, along with 22 other free SEO tools on this site. It is a direct look at how I set up crawl control before you ever become a client.
Blocking GPTBot and blocking OAI-SearchBot do completely different things, and most sites that blocked one meant the other. I make that a decision rather than an accident.
Messages get a reply within 24 hours on business days, and WhatsApp is the fastest way to reach me for anything urgent. You are not waiting in a support queue.
On a large site, crawlers waste their time on filters, search pages and parameters. I point them at what earns money instead.
"Our traffic collapsed and three agencies blamed a core update. Chirag looked at robots.txt in the first ten minutes and found a Disallow left over from the staging site. Recovered in a fortnight."
"He explained the AI crawler decision properly instead of just telling us to block everything. We allow search bots and block training bots, which is exactly what we wanted. His 17+ years really shows."
"As a small business, we started with Chirag's free robots.txt tool, then hired him. Ranked Page 1 for our main terms within 3 months. Practical, no fluff, real value."
Featured on leading media platforms. Watch interviews, expert commentary and digital marketing insights covered by top news channels and podcasts.
CMD Club Meet 2025 at Club Capri, Gurgaon : A Brief of ClipsTrust
YouTube · Business Meet
How to Build Customer 🔥Trust 🔥 - Biggest Challenges Today
Eventra vlogs
Digital Marketing Beginner to Advanced Journey | Podcast b/w Chirag Arora & Pankaj
YouTube · Podcast Episode