How to Get Your Astro Site Cited by ChatGPT, Claude and Google AI
AI assistants answer with links. What makes a site easy for them to read and cite: clear pages, structured data, a sitemap, Bing and llms.txt. Honest about what's proven.
Tested on Astro 7.4

In this guide
- First, the honest part
- 1. Let the bots in
- 2. Answer the question at the top
- 3. Use headings that are questions
- 4. Add structured data
- 5. Have a sitemap, and submit it to Bing too
- 6. Add an llms.txt file
- 7. Be the source, not the summary
- 8. Keep the basics fast and clean
- What we don’t know
- Where to go next
- Frequently asked questions
More and more people ask an AI instead of searching. When the AI answers, it often links to where it got the answer. Getting into those links is the new version of ranking on Google. Here’s what actually helps, and where the evidence is thin.
First, the honest part
Nobody outside the AI companies knows exactly how they pick sources. What we do know:
- ChatGPT’s web search uses Bing’s index. If Bing can’t find you, ChatGPT can’t cite you.
- Google’s AI answers draw from Google’s index, with the same signals as normal search.
- Claude, Perplexity and others crawl the web with their own bots and read pages much like a person skimming would.
So most of this is normal SEO, plus a few things aimed at machines reading your text.
1. Let the bots in
Open public/robots.txt. If you have lines that disallow GPTBot, ClaudeBot, PerplexityBot or Google-Extended, you’re telling the assistants to stay out. Remove those lines if you want to be cited. Ours allows everything except our search page.
2. Answer the question at the top
AI tools quote the passage that answers the question. Put a plain, complete answer in the first paragraph under each heading. Then explain. Our guides open with the answer for exactly this reason.
3. Use headings that are questions
“How much does an Astro site cost?” as a heading is easier to match to a question than “Pricing”. Write headings the way a person would ask.
4. Add structured data
Structured data is a block of JSON in your page that says what it is: an article, a how-to, a set of questions and answers. Machines read it first. Every guide on this site has an Article block and an FAQ block. Our SEO guide shows how to add them in Astro.
5. Have a sitemap, and submit it to Bing too
Add a sitemap, then submit it in Google Search Console and in Bing Webmaster Tools. Most people skip Bing. For ChatGPT, Bing is the one that matters.
6. Add an llms.txt file
llms.txt is a proposal: a plain-text file at the root of your site that lists your pages with short descriptions, so an AI can see what you have without crawling everything. Some tools read it. No one has shown it changes citations yet. Astro’s own docs team tried one and later removed it. We keep ours because it costs nothing and does no harm.
In Astro, make it a file at src/pages/llms.txt.ts that builds the text from your content:
import type { APIRoute } from 'astro';
import { getCollection } from 'astro:content';
export const GET: APIRoute = async () => {
const posts = await getCollection('posts');
const lines = [
'# My Site',
'> One line about what the site is.',
'',
'## Guides',
...posts.map((p) => `- [${p.data.title}](https://yoursite.com/${p.id}/): ${p.data.description}`),
];
return new Response(lines.join('\n'), { headers: { 'Content-Type': 'text/plain; charset=utf-8' } });
};
Change the site name and address. Build, and yoursite.com/llms.txt lists every guide. You can see ours.
7. Be the source, not the summary
AI tools prefer pages that contain something that isn’t everywhere else: a measurement you took, a thing you tested, a price you checked with a date. Every guide here says the Astro version it was run on and the date facts were checked. That’s not just honesty. It’s what makes a page worth citing.
8. Keep the basics fast and clean
Bots have budgets. A fast static site with clean HTML gets crawled fully. Astro gives you that for free. Don’t undo it with a dozen scripts.
What we don’t know
Whether llms.txt matters. How much structured data counts for AI answers specifically. Whether being cited today predicts being cited next year, as the tools change monthly. We’ll update this page as evidence appears, and change the date at the top when we do.
Where to go next
- Astro SEO guide, still most of the work.
- How to connect AI tools to the Astro docs, the other direction: AI reading docs to help you build.
Frequently asked questions
What is llms.txt?
A plain-text file at yoursite.com/llms.txt that lists your pages with one-line descriptions, written for AI tools to read. It's a proposal, not a standard. Some tools read it, and nobody has proven it changes citations. It costs nothing, so we have one.
Should I block AI crawlers?
That's your call. Blocking them means your site can't be cited. Allowing them means your writing may be summarised. For a site that wants to be found, allow them.
Does any of this replace normal SEO?
No. AI assistants mostly draw on the same search indexes as Google and Bing. Good normal SEO is still most of the work.
Stuck on a step?
Check the common errors guide, look up a word in the glossary, or ask the friendly people in the official Astro and EmDash Discords. How to ask so people can help.
