npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

astro-llms-md

v2.0.0

Published

Generate llms.txt, llms-full.txt, and individual markdown files from your Astro site with this Astro integration

Readme

astro-llms-md

npm version License: MIT

Listed on Astro Integrations: astro-llms-md on astro.build

An Astro integration to generate llms.txt, llms-full.txt, and markdown files from your Astro site.

What is llms.txt?

The llms.txt standard helps language models discover and understand your website's content. It provides:

  • llms.txt - A lightweight index of your site's pages
  • llms-full.txt - Complete content from all pages in one file
  • Individual .md files - Separate markdown files for each page

Features

  • Astro Integration - Seamless integration with Astro build process
  • Zero-config - Works out of the box with sensible defaults
  • Smart detection - Auto-detects Astro site URL from config
  • TypeScript support - Full TypeScript type definitions
  • Smart cleanup - Removes disabled file types automatically

Quick Start

1. Install

npm install -D astro-llms-md

2. Add to Astro Config

// astro.config.mjs
import { defineConfig } from "astro/config";
import llms from "astro-llms-md";

export default defineConfig({
  site: "https://your-site.com", // Required: your site URL
  integrations: [
    llms(), // That's it!
  ],
});

3. Build

npm run build

The integration automatically runs after the build and generates all files in your dist/ folder.

Integration Options

Configure the integration in astro.config.mjs:

import llms from "astro-llms-md";

export default defineConfig({
  site: "https://your-site.com",
  integrations: [
    llms({
      siteUrl: "https://your-site.com",
      name: "My Site",
      description: "A great website",
      generateIndividualMd: true,
      generateLlmsTxt: true,
      generateLlmsFullTxt: true,
      titleSelector: "h1",
      contentSelector: "main",
      exclude: ["404", "404.html", "_astro"],
      verbose: false,
    }),
  ],
});

Configuration Options

All configuration is defined in astro.config.mjs via llms({...}). The integration also uses Astro's top-level site value when siteUrl is not provided.

| Option | Type | Default | Description | | ---------------------- | ------- | ------------- | ------------------------------ | | siteUrl | string | config.site | Your site's base URL | | name | string | auto | Site name for llms.txt heading | | description | string | auto | Site description | | generateIndividualMd | boolean | true | Generate individual .md files | | generateLlmsTxt | boolean | true | Generate llms.txt index | | generateLlmsFullTxt | boolean | true | Generate llms-full.txt | | titleSelector | string | "h1" | CSS selector for page title | | contentSelector | string | "main" | CSS selector for main content | | exclude | array | see below | Patterns to exclude | | verbose | boolean | false | Detailed output |

Default Excludes

["404", "404.html", "_astro", "**.xml", "**.txt", "node_modules"]

Output Files

After building, you'll have:

llms.txt

A lightweight index file:

# Your Site Name

> Your site description

This file helps language models discover the most useful content on this site.

## Home

- [Welcome](https://your-site.com/index.md)

## Company

- [About Us](https://your-site.com/about.md): Learn about our company
- [Contact](https://your-site.com/contact.md): Get in touch

llms-full.txt

Complete content from all pages:

# Your Site Name

## Welcome

Full content from your homepage...

---

## About Us

Full content from your about page...

Individual .md Files

Each page gets its own markdown file with YAML frontmatter:

---
title: "About Us"
url: "https://your-site.com/about"
description: "Learn about our company"
---

Content converted from HTML to Markdown...

Troubleshooting

"No site URL specified"

Make sure to either:

  • Set site in astro.config.mjs
  • Pass siteUrl to the integration options

Pages not showing up

Check that your pages have:

  1. An <h1> tag (or configure titleSelector)
  2. A <main> element (or configure contentSelector)
  3. Valid HTML structure

License

MIT © Al Murad Uzzaman