llms-txt
llms.txt Generator
Generate /llms.txt and /llms-full.txt files for web projects. These files give LLMs instant context about a site's purpose, structure, brand identity, and usage guidelines -- following the llmstxt.org specification.
When to Use
- Deploying a web project to production
- Site structure, brand, or documentation has changed
- User asks for
/llms.txtor wants the site to be "AI-friendly" - As part of any new project setup (required by global convention)
Output Files
| File | Purpose | Size |
|---|---|---|
/llms.txt |
Curated index with links and LLM instructions. Always fits in context. | Small (1-5 KB) |
/llms-full.txt |
Complete site content inlined into one file. For deep analysis. | Large (10-500+ KB) |
/llms-small.txt |
Compact version with non-essential content stripped. Optional (--small flag). |
Medium (5-50 KB) |
Workflow
Phase 1: Source Analysis
Read the project to understand what it is and what it contains.
-
Identify the framework -- check
package.json, config files, directory structure:- Next.js:
next.config.*,app/orpages/ - Astro:
astro.config.*,src/pages/ - Nuxt:
nuxt.config.*,pages/ - SvelteKit:
svelte.config.*,src/routes/ - Static:
index.html,public/ - Other: infer from structure
- Next.js:
-
Map public routes/pages -- list all user-facing pages:
- For file-based routing: scan
app/,pages/,src/pages/,src/routes/ - For static sites: scan all
.htmlfiles - Note dynamic routes (e.g.,
[slug],[...catchall]) and describe the pattern - Group routes by section (docs, blog, API, marketing, etc.)
- For file-based routing: scan
-
Read existing docs -- extract project context from:
README.md,CLAUDE.md,GEMINI.md,AGENTS.mdpackage.json(name, description, keywords)- Any
docs/directory - API documentation if present
- Content schemas (TinaCMS
tina/config.ts, Contentful models, etc.)
-
Identify key resources -- find files an LLM would need:
- API routes and their purposes
- Component library or design system docs
- Configuration files that affect behavior
- Database schemas or data models
Phase 2: Brand Context
Extract brand identity from the project source and optionally the live site.
From source code:
- CSS custom properties / design tokens (colors, fonts, spacing)
- Tailwind config (
tailwind.config.*) -- theme colors, font families - Brand asset directories (
public/brand/,assets/brand/, etc.) - Style guides or voice guidelines in the repo
voice-reviewerskill config if present
From live site (if a URL is provided or discoverable):
<meta>tags: description, keywords, author, theme-color- Open Graph tags: og:title, og:description, og:image
- Favicon and apple-touch-icon (visual identity)
- CSS custom properties from the rendered stylesheet
- Existing
/robots.txtand/sitemap.xmlfor structure hints
Compose the brand profile:
Name: [project/company name]
Description: [one-line purpose]
Visual style: [e.g., "editorial travel photography, muted warm tones"]
Color palette: [extracted hex values with names]
Typography: [font families]
Tone: [e.g., "professional but approachable, concise, no jargon"]
Photography: [e.g., "real photos preferred over AI-generated, Fujifilm aesthetic"]
Phase 3: Generate /llms.txt
The file is Markdown following the llmstxt.org spec. Structure it in this order:
# {Project Name}
> {One-line description of what the project/site is}
{2-3 sentences of key context: what the site does, who it serves, what technology it uses.}
## Instructions for LLMs
{Brand guardrails and behavioral guidance for any AI agent working with or referencing this site.}
### Visual Identity
- Color palette: {extracted colors with names}
- Typography: {font families}
- Photography style: {e.g., "editorial, warm tones, shot on Fujifilm X-T4 aesthetic"}
- Image generation: {e.g., "always edit real photos, never generate from scratch. Use --prefix for steering."}
### Tone and Voice
- {tone guidelines extracted from voice docs, README, or inferred from content}
- {specific dos and don'ts}
### Technical Guidelines
- {framework-specific guidance, e.g., "this is a Next.js 16 app with App Router"}
- {API usage patterns, preferred endpoints, deprecated features}
- {version pinning notes if relevant}
## Documentation
- [Page Title](https://url): Brief description of what this page covers
- [Page Title](https://url): Brief description
{... one entry per key documentation page}
## API
- [Endpoint or API doc](https://url): Description
{... if the site has an API}
## Content
- [Section or page](https://url): Description
{... key content pages grouped logically}
## Optional
- [Secondary resource](https://url): Description
{... nice-to-have pages that can be skipped for shorter context}
Key rules for the LLM Instructions section:
- Be specific and actionable. "Use muted warm tones" is better than "be on-brand."
- Include extracted color hex values -- agents generating images or CSS need exact values.
- Reference specific tools or techniques when relevant (e.g.,
--prefixfor the openai-image skill). - If the site has voice guidelines, summarize them here.
- If the site has API endpoints, note which to prefer and which are deprecated.
- Stripe's pattern is the gold standard: explicit, practical instructions that prevent common mistakes.
Link format:
- Use absolute URLs for deployed sites
- Use relative paths for pre-deploy generation (the agent or build step can absolutize later)
- Include the
.mdsuffix convention if the site supports it:https://example.com/docs/setup.md
Phase 4: Generate /llms-full.txt
Concatenate key page content into a single file. Structure:
# {Project Name} -- Full Documentation
> {Same description as /llms.txt}
## Instructions for LLMs
{Same instructions section as /llms.txt -- always include this at the top}
---
## {Section: e.g., Getting Started}
{Full content of the page, converted to clean markdown}
---
## {Section: e.g., API Reference}
{Full content of the page}
{... repeat for all key pages}
Content sources (in priority order):
- Markdown/MDX source files in the repo (cleanest, no HTML stripping needed)
- Built output (
.next/,dist/,out/) parsed to markdown - Live site pages fetched and converted to markdown
What to include: Documentation, guides, API reference, key content pages. What to exclude: Navigation chrome, footers, cookie banners, marketing boilerplate, duplicate content from shared layouts.
Phase 5: Generate /llms-small.txt (Optional)
Only when requested or when --small flag is used. Create a compact version by:
- Start from
/llms.txt(the index) - Inline only the most critical 3-5 pages (getting started, API overview, key concepts)
- Summarize rather than dump -- one paragraph per page instead of full content
- Keep the LLM Instructions section intact (never abbreviate this)
- Drop the "Optional" section entirely
Output Placement
Place generated files based on the framework:
| Framework | Output directory |
|---|---|
| Next.js | public/ |
| Astro | public/ |
| Nuxt | public/ |
| SvelteKit | static/ |
| Static HTML | root / |
| Other | root / (ask user if unclear) |
The files must be served at the root URL path: https://example.com/llms.txt, not nested under a subdirectory.
Agent Behavior
When invoked, the agent should:
- Check for existing files. If
/llms.txtalready exists, read it and ask whether to regenerate or update. - Ask for the live URL if not obvious from the project config (e.g.,
vercel.json,CNAME, deployment config). - Run all five phases in order. Phases 1-2 are analysis, Phases 3-5 are generation.
- Show the LLM Instructions section to the user for review before writing. This section captures brand identity and behavioral rules -- the user should validate it.
- Write the files to the correct output directory.
- Report what was generated with file sizes and a summary of content coverage.
Updating Existing Files
When a site's /llms.txt needs updating (new pages, changed brand, etc.):
- Read the existing file
- Re-run Phase 1 (source analysis) to detect changes
- Diff the route map against the existing links
- Add new pages, remove deleted pages, update descriptions for changed pages
- Preserve any manually-added content in the Instructions section
- Regenerate
/llms-full.txtfrom scratch (content changes make diffs unreliable)
Integration with Other Skills
- openai-image: The LLM Instructions section should include image generation guidance (style, prefix templates, provider preference). Any agent hitting
/llms.txtbefore generating images for the site gets brand-appropriate defaults. - voice-reviewer: If voice guidelines exist, summarize them in the Tone and Voice subsection.
- gs-brand-doc: Brand colors and typography extracted here can inform PDF generation.
- kitchen-sink-design-system: Design token extraction overlaps -- reuse the component inventory if available.
- nextjs-tinacms: Content schema from TinaCMS config informs the content structure section.
Agentic Workflow & Vibe Coding
- Iterative Extraction: Do not expect perfect context files on the first generation. Draft the initial
llms.txt, review the extracted brand identity and route map, isolate any missing or misinterpreted context, adjust the extraction logic or source files, and regenerate until the file accurately represents the site. - Vibe Coding: Commit the generated
llms.txtandllms-full.txtfiles locally alongside the structural or brand changes that necessitated their creation, ensuring agents always have the latest context.
Validation
After generation, verify:
- H1 heading is present and matches the project name
- Blockquote summary is present and under 200 characters
- Instructions for LLMs section exists with at least Visual Identity and Tone subsections
- All links resolve (no 404s for absolute URLs, no missing files for relative paths)
-
/llms-full.txtstarts with the Instructions section - Files are in the correct output directory for the framework
- No HTML tags leaked into the markdown (clean conversion)
- File sizes are reasonable:
/llms.txtunder 10 KB,/llms-full.txtunder 1 MB
Examples
See references/examples.md for annotated real-world examples from Stripe, Next.js, Astro, and Supabase.
See templates/llms.txt.md for the starter template.
More from baphomet480/claude-skills
kitchen-sink-design-system
Kitchen Sink design system workflow for Next.js and React projects, with secondary support for Astro, SvelteKit, Nuxt, and static HTML. Use when asked for a Kitchen Sink page, Design System, UI Audit, Style Guide, or Component Inventory, or when a project needs a component inventory plus component creation and a sink page implementation. Covers CVA variant architecture, Tailwind v3/v4 token systems, shadcn/ui integration, and TinaCMS content modeling.
40deep-research
Conduct comprehensive, multi-round research that produces rich visual reports. Use when asked for "deep research", "comprehensive analysis", "compare frameworks", "evaluate options", "research the state of X", or any task requiring investigation across 10+ sources. NOT for quick lookups — this is a 5-15 minute deep dive that produces a briefing-quality artifact with screenshots, diagrams, tables, and cited findings.
37design-lookup
Search and retrieve CSS components, SVG icons, design patterns, and visual inspiration from the web. Use when the user asks to find, look up, or search for CSS snippets, SVG icons, UI components, loading spinners, animations, design inspiration, or any visual/frontend design resource. Triggers on requests like "find me a CSS button", "look up an SVG spinner", "search for a card component", "find a wave divider SVG", or "get design inspiration for a dashboard".
34nextjs-tinacms
Build Next.js 16 + React 19 + TinaCMS sites with visual editing, blocks-based page builder, and complete SEO. Use this skill whenever the user mentions TinaCMS, Tina CMS, Next.js with a CMS, visual editing with Next.js, click-to-edit, content-managed Next.js site, blocks pattern page builder, or migrating to Next.js + TinaCMS. Also trigger for TinaCMS schema design, self-hosted TinaCMS, TinaCMS media configuration, or any TinaCMS troubleshooting. Covers Day 0-2 setup from scaffolding through production deployment on Vercel.
32cloudflare-pages
Deploy static sites to Cloudflare Pages with custom domains and CI/CD. Use when the user wants to deploy a site to Cloudflare Pages, add a custom domain to a Pages project, set up GitHub Actions CI/CD for Cloudflare Pages, roll back a deployment, or verify deployment status. Triggers on "deploy to Cloudflare", "Cloudflare Pages", "add custom domain", "pages deploy", or any Cloudflare Pages hosting workflow.
31local-ocr
Local OCR pipeline for AI agents featuring auto-rotation, deskew, and searchable PDF generation via ocrmypdf and Tesseract.
23