🤖robots.txt 生成器

为您的网站生成 robots.txt 文件。通过 User-agent、Allow 和 Disallow 规则控制爬虫访问。

robots.txt 生成器

通过表单生成并导出 robots.txt

使用 * 匹配所有爬虫

User-agent: *
Disallow: /admin/
Disallow: /private/

Sitemap: https://example.com/sitemap.xml

关于 robots.txt 生成器

robots.txt 生成器可帮助您在几秒内创建符合标准的 robots.txt 文件。可按 user-agent 定义规则,设置 Allow 和 Disallow 路径,添加 sitemap URL,并配置抓取延迟。实时预览生成的文件,并一键复制到您的网站根目录。对 SEO 和控制搜索引擎抓取您的网站至关重要。

主要特性

  • 按 user-agent 定义规则(Googlebot、Bingbot 等)
  • 设置支持通配符的 Allow 和 Disallow 路径
  • 添加多个 sitemap URL
  • 按机器人配置抓取延迟
  • 实时预览并一键复制 robots.txt

常见问题

我应该把 robots.txt 文件放在哪里?
将生成的 robots.txt 文件上传到网站的根目录,使其可通过 https://yourdomain.com/robots.txt 访问。
robots.txt 会阻止页面被索引吗?
robots.txt 控制的是抓取,而不是索引。要阻止页面被索引,应在 robots.txt 中禁止之外,额外使用 noindex 元标记或 HTTP 标头。