Prompt to score a site for AI readiness

Short answer

This prompt asks an AI assistant to check what an AI crawler can read on your site: the robots.txt rules for named AI bots, llms.txt, sitemap, JSON-LD, and whether page text is present without JavaScript. It writes a pass or fail checklist with fixes in order. It never edits robots.txt on its own.

Last reviewed

Key facts

  • This is a plain checklist, not an industry score. Each line is a fact you can verify with curl.
  • Whether to allow or block an AI crawler is a business decision. The prompt reports, and you decide.
  • A crawler that does not run JavaScript sees only the raw HTML. A plain fetch shows exactly that.
  • Test status: the reference script was run on webexport.online and passed 24 of 24 checks, and on example.com, where it failed 9 of 11 (no robots.txt, llms.txt or sitemap, no JSON-LD, 27 words and no h1 on the home page). The assistant-written fix list was not run.

The prompt

Paste this into Claude Code, Cursor, Codex or another AI coding assistant with your project folder open, and replace everything in square brackets first. See how to run it in each tool.

Check AI readiness
You are checking how well a website can be read by AI crawlers and answer engines. The site is [LIVE_URL], or the exported folder [EXPORT_FOLDER].

READ ONLY THESE
- /robots.txt, /llms.txt, /llms-full.txt and /sitemap.xml
- The raw HTML of the home page and up to [SAMPLE_PAGES: 5] other pages, fetched with a plain GET so JavaScript does not run

CHECKS
1. robots.txt: for each of these user agents say whether the rules allow or block the whole site: [BOTS: GPTBot, OAI-SearchBot, ChatGPT-User, ClaudeBot, Claude-SearchBot, Claude-User, PerplexityBot, Perplexity-User, Google-Extended, CCBot]. Use the group for that agent, otherwise the * group. Note any rule that blocks only part of the site.
2. llms.txt exists and starts with a title line. llms-full.txt exists.
3. sitemap.xml exists and lists the pages you sampled.
4. JSON-LD: list the types found on each sampled page and say whether the JSON parses.
5. Text without JavaScript: count the words in the raw HTML of each sampled page. Flag any page under 150 words.
6. Each sampled page has one h1, a title, a meta description, a canonical link and a lang attribute, and is not marked noindex.

OUTPUT
Write AI-READINESS.md with a PASS or FAIL line per check, the evidence (status code, word count, rule text), then a numbered fix list ordered by how many pages each fix helps.

RULES
- Do not edit robots.txt, llms.txt or any page. Propose changes only.
- Do not treat a blocked bot as an error. Report it as a choice the owner made, unless the block looks accidental (a blanket Disallow on / for all agents).
- Do not claim the site is "AI ready" or give a score out of 100. Report the checklist count only.
- If scripts/ai-readiness.mjs exists, use it.

How to run it

  1. Decide which pages are a fair sample: the home page, one product or pricing page, and a few articles.
  2. Run the prompt on the live site, or on a preview of the export before you launch.
  3. Read AI-READINESS.md and decide for each bot whether the current rule is what you want.
  4. Apply the fixes you accept as separate commits, then run the check again.

Run it without a paid key

This script runs the same checklist with plain fetch calls. Its robots.txt reader finds the group for each bot, falls back to the * group, and reports BLOCKED only when the group has a Disallow of / and no Allow of /. It ignores path-level rules, so read robots.txt yourself when the result matters.

scripts/ai-readiness.mjs
// Usage: node ai-readiness.mjs https://example.com
// A plain checklist for AI crawlers and answer engines. It is not an industry score.
const origin = new URL(process.argv[2] ?? '').origin;
const get = async (path) => { try { const r = await fetch(origin + path, { signal: AbortSignal.timeout(15000), headers: { 'user-agent': 'ai-readiness/1.0' } }); return { status: r.status, text: await r.text(), headers: r.headers }; } catch { return { status: 0, text: '', headers: new Headers() }; } };
const BOTS = ['GPTBot', 'OAI-SearchBot', 'ChatGPT-User', 'ClaudeBot', 'Claude-SearchBot', 'Claude-User', 'PerplexityBot', 'Perplexity-User', 'Google-Extended', 'CCBot'];

function blockedBy(robots, bot) {
  const groups = []; let cur = null;
  for (const raw of robots.split('\n')) {
    const line = raw.replace(/#.*/, '').trim(); const m = line.match(/^([a-z-]+)\s*:\s*(.*)$/i); if (!m) continue;
    const key = m[1].toLowerCase();
    if (key === 'user-agent') { if (!cur || cur.rules.length) { cur = { agents: [], rules: [] }; groups.push(cur); } cur.agents.push(m[2].toLowerCase()); }
    else if (cur && (key === 'disallow' || key === 'allow')) cur.rules.push([key, m[2]]);
  }
  const g = groups.find((x) => x.agents.includes(bot.toLowerCase())) ?? groups.find((x) => x.agents.includes('*'));
  if (!g) return 'allowed (no rule)';
  const blocked = g.rules.some(([k, v]) => k === 'disallow' && v === '/') && !g.rules.some(([k, v]) => k === 'allow' && v === '/');
  return blocked ? 'BLOCKED' : 'allowed';
}
const words = (h) => h.replace(/<(script|style|noscript|svg)[\s\S]*?<\/\1>/gi, ' ').replace(/<[^>]+>/g, ' ').replace(/&[#\w]+;/g, ' ').split(/\s+/).filter(Boolean).length;

const checks = [];
const add = (name, pass, detail) => checks.push({ name, pass, detail });

const robots = await get('/robots.txt');
add('robots.txt exists', robots.status === 200, `HTTP ${robots.status}`);
if (robots.status === 200) for (const b of BOTS) { const v = blockedBy(robots.text, b); add(`robots.txt: ${b}`, v !== 'BLOCKED', v); }
const llms = await get('/llms.txt');
add('llms.txt exists', llms.status === 200 && llms.text.trim().startsWith('#'), `HTTP ${llms.status}${llms.status === 200 ? ', starts with ' + JSON.stringify(llms.text.trim().slice(0, 30)) : ''}`);
add('llms-full.txt exists', (await get('/llms-full.txt')).status === 200, '');
const sm = await get('/sitemap.xml');
add('sitemap.xml exists', sm.status === 200, `HTTP ${sm.status}, ${(sm.text.match(/<loc>/g) ?? []).length} <loc> entries`);

const home = await get('/');
const raw = home.text;
const ld = [...raw.matchAll(/<script[^>]+application\/ld\+json[^>]*>([\s\S]*?)<\/script>/gi)].map((m) => { try { return JSON.parse(m[1]); } catch { return null; } });
const types = ld.filter(Boolean).flatMap((j) => (j['@graph'] ?? [j]).map((n) => n['@type'])).flat().filter(Boolean);
add('JSON-LD present and valid', ld.length > 0 && ld.every(Boolean), `${ld.length} block(s): ${types.join(', ') || 'none'}`);
add('Home page text visible without JavaScript (150+ words)', words(raw) >= 150, `${words(raw)} words in the raw HTML`);
add('One h1', (raw.match(/<h1[\s>]/gi) ?? []).length === 1, `${(raw.match(/<h1[\s>]/gi) ?? []).length} found`);
add('Title and meta description', /<title>[^<]+/.test(raw) && /name=["']description["']/.test(raw), '');
add('Canonical link', /rel=["']canonical["']/.test(raw), '');
add('lang attribute on <html>', /<html[^>]+lang=/i.test(raw), '');
add('Not noindex', !/noindex/i.test((raw.match(/<meta[^>]+name=["']robots["'][^>]*>/i)?.[0] ?? '') + (home.headers.get('x-robots-tag') ?? '')), '');

const sample = [...sm.text.matchAll(/<loc>\s*([^<\s]+)/g)].map((m) => new URL(m[1]).pathname).filter((p) => p !== '/').slice(0, 3);
for (const p of sample) { const r = await get(p); add(`${p} has 150+ words without JavaScript`, words(r.text) >= 150, `${words(r.text)} words`); }

for (const c of checks) console.log(`${c.pass ? 'PASS' : 'FAIL'}  ${c.name}${c.detail ? '  (' + c.detail + ')' : ''}`);
console.log(`\n${checks.filter((c) => c.pass).length} of ${checks.length} checks passed for ${origin}`);

Where each bot is documented

Names and purposes change, so read the vendor page before you write a rule. These are the pages used for the bot list above, all opened on 2026-11-29.

User agentOperatorDocumented at
GPTBot, OAI-SearchBot, ChatGPT-UserOpenAIOpenAI crawler docs
ClaudeBot, Claude-SearchBot, Claude-UserAnthropicAnthropic help article
PerplexityBot, Perplexity-UserPerplexityPerplexity crawler docs
Google-ExtendedGoogleGoogle crawlers and fetchers
CCBotCommon CrawlCommon Crawl CCBot page

You do not need Firecrawl for this check. A crawler that does not run JavaScript sees the raw response, and a plain request returns exactly that.

Verify the result

Confirm the key facts yourself with curl before you act on the report.

terminal
curl -s https://example.com/robots.txt | head -30
curl -s -o /dev/null -w "%{http_code}\n" https://example.com/llms.txt
curl -s https://example.com/ | sed 's/<script.*<\/script>//g' | grep -c "<h1"
curl -s https://example.com/ | grep -o 'application/ld+json' | wc -l
  • The robots.txt lines match what the report quotes for each bot.
  • The word count for a sampled page is close to what you see when you disable JavaScript in the browser.
  • After a fix, the same check line moves from FAIL to PASS on a second run.

What can go wrong

  • A rule that looks right can still be overridden by a more specific group. Read the whole file.
  • Blocking a crawler can cut how often your pages appear in that product's answers. Decide with the cost in mind.
  • llms.txt is a proposal, and crawlers differ in whether they read it. It is a low-cost extra with no documented ranking effect.

Frequently asked questions

Does llms.txt change my ranking?

We found no search engine documentation that calls it a ranking signal. It is a proposal at llmstxt.org for giving language models a short, readable index of a site. Add it if it costs you little.

Should I allow every AI bot?

That is your call. Anthropic, for example, documents ClaudeBot for collecting content that may be used in training, Claude-SearchBot for improving search results, and Claude-User for fetches a person asks for. Read each vendor page, then decide bot by bot.

Why check text without JavaScript?

Not every crawler runs scripts. A page whose text arrives by JavaScript can look empty to one that does not. Exported static pages usually pass.

Is there a tool for part of this?

The robots.txt Tester checks a path against a bot, and the Website MD File Generator turns a page into Markdown.

Official documentation

Free tools for this job

Start with the files

Prompts work best on a WebExport download of your site. Paste your public URL into the export form and get a ZIP. The Free plan covers 1 site, 5 exports a month, 15 pages and 20 MB per export. Professional is a $9.99 one-time purchase with unlimited pages.