Robots.txt Generator

Build a correct robots.txt file in seconds. Choose what search engines may crawl, block folders such as /admin/, add your sitemap, set a crawl delay, and optionally block AI training crawlers. Download it ready to upload.

Your rules

By default, search engines may

One path per line, starting with /. End folders with /.

Exceptions inside blocked folders.

Bing and Yandex respect this; Google ignores it.

robots.txt

    How to use the Robots.txt Generator

    1. Choose whether crawlers may visit the whole site.
    2. List any folders or pages to block, and your sitemap address.
    3. Download robots.txt and upload it to the top folder of your website.

    Your data stays on your device. This tool runs entirely in your browser. Nothing you type or paste is sent to our server or saved. Read our privacy policy.

    What robots.txt does

    robots.txt is a small text file at the top of a website, at example.com/robots.txt. Search engine crawlers read it first to learn which parts of the site they may visit. It also tells them where your sitemap is.

    A typical robots.txt

    User-agent: *
    Disallow: /admin/
    Disallow: /cart/
    Sitemap: https://example.com/sitemap.xml

    Important rules

    • Blocking isn't hiding. A disallowed page can still appear in Google if other sites link to it. Use a noindex meta tag to keep a page out of results, and passwords for private content.
    • Don't block CSS and JavaScript files; Google needs them to see your pages properly.
    • One mistake can hide your whole site: Disallow: / blocks everything. Double-check before uploading.
    • Paths are case-sensitive and must start with /.

    Blocking AI training crawlers

    Crawlers such as GPTBot, CCBot and Google-Extended collect pages for training AI models. You can block them without affecting normal search results. Well-behaved bots follow robots.txt; it isn't a security measure against those that don't.

    Uploading and testing

    Upload the file to the top folder of your site (on most hosts, public_html or htdocs), open yoursite.com/robots.txt to check it, and look at the robots.txt report in Google Search Console.

    Frequently asked questions

    Where does robots.txt go?

    In the top folder of your website, so it opens at example.com/robots.txt. On InfinityFree and most hosts that is the htdocs or public_html folder.

    Does robots.txt hide pages from Google?

    Not completely. It asks crawlers not to visit pages, but a blocked page can still appear in results if other sites link to it. To keep a page out of search results, use a noindex meta tag instead.

    Should I block AI crawlers?

    It’s your choice. Blocking crawlers such as GPTBot and CCBot asks AI companies not to use your pages for training. It doesn’t affect Google or Bing search results.