Skip to main content

docs-site

PyPI CI Python versions License: MIT

Turn a folder of Markdown, HTML, and PDF files into a clean, searchable, dark-mode-ready local documentation site with built-in LLM support.

Features

  • Static & Offline: Generates a self-contained static site with zero runtime server required. Works out of the box with file:/// URLs or any static host.
  • Multi-Format Processing:
    • Markdown (.md, .markdown): Rendered with syntax highlighting, tables, and admonitions.
    • HTML (.html, .htm): Formatted with isolated reader styling and link rewriting.
    • PDF (.pdf): Integrated directly with bookmark outlines and portable file bundling.
  • Fast Client-Side Search: Full-text MiniSearch indexing across titles, filenames, relative paths, headings, and body text, with Google-style "quoted phrase" matching, clipboard phrase handoff (Ctrl+F / ⌘F), in-dropdown match preview cycling (‹ 1 / N › via ←/→), and keyboard navigation (↑/↓/←/→/Enter/Esc).
  • LLM-Ready Workflows:
    • Copy Page: One-click button in the header toolbar copies the active page's clean, structured Markdown to your clipboard.
    • Standardized llms.txt: Automatically creates llms.txt index and llms-full.txt corpus following the llmstxt.org standard.
    • CLI Pipe: Dump clean Markdown directly to stdout for CLI piping (e.g. docs-site docs/ --dump | llm).
  • Responsive Navigation & TOC: Sidebar shows document titles with base filenames, collapses into an off-canvas drawer on narrow screens (< 850px), and keeps the "On this page" Table of Contents accessible in a header popover between 850px and 1149px.
  • Dark Mode: Built-in dark/light theme toggle, synchronized across framed documents and welcome screen.
  • Zero Configuration: Recursively scans folders while automatically ignoring .git, .venv, node_modules, and hidden directories.

Installation

Install globally as a CLI tool using uv:

uv tool install docs-site

Alternatively, install with pipx:

pipx install docs-site

Or with plain pip, ideally inside a virtual environment:

pip install docs-site

Usage

Build and Browse

# Build and open the site in your default browser
docs-site ~/notes/linux-learning

# Specify a custom output directory (default is <folder>/_site)
docs-site ~/notes/linux-learning -o ~/public_html/docs

# Build without automatically opening the browser
docs-site ~/notes/linux-learning --no-open

# Skip generating llms.txt and llms-full.txt
docs-site ~/notes/linux-learning --no-llms-txt

# Choose how document titles are resolved:
#   auto     (default) HTML <title>/<h1>, Markdown <h1>, PDF metadata, then file stem
#   h1       First <h1> / PDF outline heading, falling back to file stem
#   filename Always use the file stem
docs-site ~/notes/linux-learning --title-source filename

# Display version
docs-site --version

# View all options
docs-site --help

CLI Reference

Option Description
folder Folder or single file to scan (.md, .markdown, .html, .htm, .pdf)
-o, --output DIR Custom output directory (default: <folder>/_site)
--no-open Build the static site without launching the browser
--no-llms-txt Skip generating llms.txt and llms-full.txt
--title-source {auto,h1,filename} Control how primary document titles are resolved (default: auto)
--dump Print clean Markdown to stdout instead of building a site
--file TARGET Relative path or filename to print when using --dump
--version Show installed docs-site version and exit

CLI Pipe Workflow (LLMs & Tooling)

You can pipe clean Markdown straight to tools like llm without creating a site directory or launching a browser:

# Dump entire corpus as consolidated Markdown
docs-site ~/notes/linux-learning --dump | llm "summarize these notes"

# Dump a specific file
docs-site ~/notes/linux-learning --dump --file guide.md | llm "explain section 2"

# Dump a single file directly
docs-site ~/notes/linux-learning/guide.pdf --dump | llm "extract key concepts"

Project Scope & Constraints

  • Supported Formats: .md, .markdown, .html, .htm, and .pdf files.
  • Portable Output: All generated pages, markdown artifacts, and referenced PDFs are copied into the output directory, making -o <custom-dir> self-contained.
  • Clean Rebuilds: Output pages/ directory is cleanly recreated on rebuilds to eliminate stale files from deleted sources.
  • Indexing Cap: Indexed full text is capped at 400,000 characters per file in the manifest to keep client-side memory lightweight.

Contributing

Looking to work on docs-site itself? See CONTRIBUTING.md for the development setup, testing, and architecture overview.

License

This project is licensed under the MIT License.

Metadata

Release files for docs-site 0.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for docs-site 0.3.0
File Size Uploaded Provenance Actions
docs_site-0.3.0.tar.gz 45.7 kB With provenance Details for docs_site-0.3.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for docs-site 0.3.0
File Interpreter ABI Platform Actions
docs_site-0.3.0-py3-none-any.whl Python 3 none any Details for docs_site-0.3.0-py3-none-any.whl

Total release size: 90.5 kB

Release files / docs_site-0.3.0.tar.gz

Download URL docs_site-0.3.0.tar.gz
Size 45.7 kB
Tags Source
SHA-256 checksum
How to use checksums
1e704b86bb5047ab8d1b20de3783f2bf975c803a5e8be979b33c796c3462469e
BLAKE2b-256 checksum
How to use checksums
f5785e51ce3f9ef9820f6bd5d6012e6345dfade0c3fab3295bc81158943b2fc8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 25, 2026.

Transparency log

Release files / docs_site-0.3.0-py3-none-any.whl

Download URL docs_site-0.3.0-py3-none-any.whl
Size 44.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
1961a8595c175035d2fe95dde1419c2a0aa6fa1eecab6bf14f6f53cb89a48678
BLAKE2b-256 checksum
How to use checksums
1336a3dd027bb9884118bdbf9b1c50b8531544da9ce699ebcb847bcfeeb85790
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 25, 2026.

Transparency log

Security for docs-site 0.3.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for docs_site-0.3.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 25, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page