# Markdown Documentation Server
A lightweight, fast, and beautiful documentation server that renders Markdown files as styled HTML with zero configuration.
## Project Overview
This is a modern documentation server built with Python, FastAPI, and powerful Markdown extensions. It's designed to be:
- **Zero-config**: Drop markdown files and go
- **Beautiful**: Nuxt UI-inspired design
- **AI-friendly**: Built-in llms.txt support
- **Production-ready**: Docker, caching, testing
## Quick Links
Essential starting points:
- [Homepage](http://static.109.5.225.46.clients.your-server.de/index.md) - Project overview and introduction
- [Quick Setup Guide](http://static.109.5.225.46.clients.your-server.de/quick-setup.md) - Get running in 5 minutes
- [Configuration](http://static.109.5.225.46.clients.your-server.de/configuration.md) - Environment variables and settings
## Core Documentation
### Getting Started
- [Quick Setup Guide](http://static.109.5.225.46.clients.your-server.de/quick-setup.md) - Installation and first steps
- [Configuration](http://static.109.5.225.46.clients.your-server.de/configuration.md) - Environment variables, file structure, and settings
### Features
- [Markdown Features](http://static.109.5.225.46.clients.your-server.de/features/markdown.md) - Complete markdown capabilities showcase
- [Navigation Guide](http://static.109.5.225.46.clients.your-server.de/features/navigation.md) - Sidebar and topbar configuration
- [LLMs.txt Support](http://static.109.5.225.46.clients.your-server.de/features/llms-txt.md) - AI assistant integration (remarkable!)
- [Caching System](http://static.109.5.225.46.clients.your-server.de/features/caching.md) - How the intelligent cache works
### Deployment
- [Docker Deployment](http://static.109.5.225.46.clients.your-server.de/deployment/docker.md) - Container-based deployment
- [Environment Variables](http://static.109.5.225.46.clients.your-server.de/deployment/environment.md) - Production configuration
- [Production Tips](http://static.109.5.225.46.clients.your-server.de/deployment/production.md) - Best practices and optimization
### API Reference
- [HTTP Endpoints](http://static.109.5.225.46.clients.your-server.de/api/endpoints.md) - All available API endpoints
- [Response Formats](http://static.109.5.225.46.clients.your-server.de/api/responses.md) - Response structures and status codes
### Architecture
- [Architecture Overview](http://static.109.5.225.46.clients.your-server.de/architecture/overview.md) - System design and components
- [Code Structure](http://static.109.5.225.46.clients.your-server.de/architecture/structure.md) - Module organization and patterns
- [Testing Strategy](http://static.109.5.225.46.clients.your-server.de/architecture/testing.md) - Test coverage and approach
### Examples
- [Basic Setup](http://static.109.5.225.46.clients.your-server.de/examples/basic.md) - Simple configuration examples
- [Advanced Features](http://static.109.5.225.46.clients.your-server.de/examples/advanced.md) - Complex use cases
- [Custom Styling](http://static.109.5.225.46.clients.your-server.de/examples/styling.md) - Theming and customization
## Key Features
This server provides remarkable capabilities:
1. **Rich Markdown**: Tables, code highlighting, task lists, footnotes, and more
2. **Beautiful UI**: Three-column responsive layout with sidebar, content, and TOC
3. **AI Integration**: Native llms.txt and llms-full.txt endpoints
4. **Smart Caching**: Automatic HTML caching for fast performance
5. **Security**: Path traversal protection built-in
6. **Docker Ready**: Production-optimized container
7. **Well Tested**: 71 tests with 100% pass rate
8. **Modern Python**: FastAPI, async/await, type hints
## Technical Details
- **Language**: Python 3.13+
- **Framework**: FastAPI
- **Markdown**: Python-Markdown with extensions
- **Styling**: CSS3 with modern design
- **Testing**: pytest with 71 tests
- **Linting**: Ruff for code quality
- **Package Manager**: uv for fast installs
## Project Structure
```
docs_server/
├── config.py # Settings and environment
├── helpers.py # Utilities and navigation
├── caching.py # Cache operations
├── markdown_service.py # Markdown rendering
├── llms_service.py # LLMs.txt generation
├── templates.py # HTML templates
└── main.py # FastAPI routes
```
## Use Cases
Perfect for:
- **Open Source Projects**: Self-hosted documentation
- **Internal Teams**: Company documentation portals
- **API Documentation**: REST/GraphQL API docs
- **Technical Writing**: Blog posts and tutorials
- **Knowledge Bases**: Internal wikis
## Community
- **GitHub**: github.com/yourusername/markdown-docs-server
- **License**: MIT
- **Python Version**: 3.13+ recommended
- **Dependencies**: FastAPI, Python-Markdown, Pygments, Uvicorn
## Getting Help
If you need assistance:
1. Check the [Configuration Guide](http://static.109.5.225.46.clients.your-server.de/configuration.md)
2. Review [Examples](http://static.109.5.225.46.clients.your-server.de/examples/basic.md)
3. Open a GitHub issue
4. Read the [Troubleshooting](http://static.109.5.225.46.clients.your-server.de/configuration.md#troubleshooting) section
## What Makes This Special?
Unlike static site generators (Hugo, Jekyll, MkDocs), this is a **live server** that:
- Renders markdown on-demand
- No build step required
- Hot reload in development
- Dynamic caching
- API endpoints for integrations
- Native AI assistant support
## Quick Command Reference
```bash
# Development
DOCS_ROOT=./docs DEBUG=true uv run python -m docs_server
# Production
DOCS_ROOT=/app/docs BASE_URL=https://docs.site.com uv run python -m docs_server
# Docker
docker run -p 8080:8080 -v $(pwd)/docs:/app/docs markdown-docs-server
# Testing
uv run pytest tests/ -v
# Linting
uv run ruff check src/
```
## Status
✅ Production Ready
✅ Well Tested (71 tests, 100% passing)
✅ Fully Documented
✅ Docker Optimized
✅ Type Hinted
✅ Linted and Formatted
---
For the complete documentation, visit any page listed above or explore the sidebar navigation.
http://static.109.5.225.46.clients.your-server.de/index.md
# Markdown Documentation Server
A **lightweight, fast, and beautiful** documentation server that renders Markdown files as styled HTML with zero configuration.
## 🚀 What Makes This Special?
This isn't just another static site generator. It's a **live documentation server** with remarkable features:
### ✨ Zero Configuration
- Drop your `.md` files in a folder
- Start the server
- Beautiful docs instantly available
### 🎨 Beautiful Design
- Inspired by [Nuxt UI](https://ui.nuxt.com/) documentation
- Three-column layout (sidebar, content, table of contents)
- Responsive design for mobile/tablet/desktop
- Dark mode ready with customizable colors
### 🤖 AI-Friendly
- **llms.txt** support for AI assistants
- **llms-full.txt** for complete context
- **MCP endpoint** for interactive queries (250x less context)
- Automatic link transformation
- Optimized for Claude, ChatGPT, and other LLMs
### ⚡ Performance
- Intelligent caching system
- Fast markdown rendering
- Minimal dependencies
- Production-ready Docker image
### 🎯 Developer Experience
- Hot reload in development
- Clear error messages
- Type hints everywhere
- Comprehensive test suite (71 tests, 100% passing)
---
## 📚 Quick Start
### Installation
```bash
# Clone the repository
git clone https://github.com/yourusername/markdown-docs-server
cd markdown-docs-server
# Install dependencies with uv (recommended)
pip install uv
uv sync
# Or with pip
pip install -e .
```
### Run Locally
```bash
# Development mode (auto-reload)
uv run python -m docs_server
# Or with environment variables
DOCS_ROOT=./my-docs PORT=8080 uv run python -m docs_server
```
Visit `http://localhost:8080` and see your documentation come to life! 🎉
---
## 🐳 Docker Deployment
### Quick Start
```bash
# Build the image
docker build -t markdown-docs-server .
# Run with your docs
docker run -p 8080:8080 \
-v $(pwd)/my-docs:/app/docs \
markdown-docs-server
```
### Production Deployment
```bash
# With environment variables
docker run -d \
-p 8080:8080 \
-e BASE_URL=https://docs.example.com \
-e DEBUG=false \
-v $(pwd)/docs:/app/docs \
--restart unless-stopped \
--name docs-server \
markdown-docs-server
```
---
## 📖 Documentation Structure
Your documentation needs just **3 required files** and 1 optional:
```
docs/
├── index.md # Homepage (required)
├── sidebar.md # Navigation structure (required)
├── topbar.md # Top bar navigation (required)
└── llms.txt # AI assistant index (optional)
```
All other `.md` files are your content pages!
---
## 🎯 Key Features
| Feature | Description |
|---------|-------------|
| **Markdown Extensions** | Tables, code highlighting, TOC, task lists, and more |
| **Navigation** | Sidebar with groups, topbar with sections |
| **Caching** | Smart caching for fast performance |
| **Security** | Path traversal protection |
| **Dual Mode** | Serve HTML or raw markdown |
| **Assets** | Images, PDFs, videos supported |
| **LLMs.txt** | Built-in AI assistant support |
| **MCP Support** | Interactive queries via JSON-RPC (250x less context) |
| **Responsive** | Mobile-first design |
---
## 🌟 What You're Seeing Now
This documentation is **powered by the server itself**! Every feature you see here is built-in:
- ✅ The beautiful three-column layout
- ✅ Syntax-highlighted code blocks
- ✅ Responsive navigation
- ✅ Automatic table of contents
- ✅ Markdown tables
- ✅ Task lists
- ✅ And much more!
---
## 🔍 Learn More
Explore the documentation to see all features in action:
- [**Quick Setup Guide**](quick-setup.md) - Get started in 5 minutes
- [**Markdown Features**](features/markdown.md) - See what's possible
- [**Navigation Guide**](features/navigation.md) - Create beautiful menus
- [**LLMs.txt Guide**](features/llms-txt.md) - AI assistant integration
- [**MCP Integration**](features/mcp.md) - Interactive queries for LLMs
- [**Docker Deployment**](deployment/docker.md) - Production deployment
- [**API Reference**](api/endpoints.md) - HTTP endpoints
- [**Configuration**](configuration.md) - Environment variables
---
## 💡 Why This Server?
### For Documentation Teams
- **Zero learning curve** - just write Markdown
- **Beautiful by default** - no CSS needed
- **Fast deployment** - Docker ready
### For Open Source Projects
- **GitHub-friendly** - works with GitHub Pages
- **Self-hosted** - own your docs
- **Modern design** - professional appearance
### For AI/LLM Integration
- **llms.txt native** - built-in AI support
- **Context optimization** - smart link transformation
- **Full content export** - llms-full.txt endpoint
---
## 🎨 Customization
While the default theme is beautiful, you can customize:
- Colors (CSS variables)
- Logo (place in `assets/`)
- Navigation structure (sidebar.md, topbar.md)
- Content organization (any folder structure)
---
## 🧪 Quality
This is a **production-ready** server with:
- ✅ **71 unit tests** (100% passing)
- ✅ **Type hints** everywhere
- ✅ **Linting** with Ruff
- ✅ **CI/CD** ready
- ✅ **Docker** optimized
- ✅ **Security** focused
---
## 🤝 Contributing
Contributions welcome! This server is:
- 🐍 **Python 3.13+** with modern features
- ⚡ **FastAPI** for performance
- 📦 **uv** for fast dependency management
- 🧪 **pytest** for comprehensive testing
---
## 📜 License
MIT License - use it freely for any project!
---
## 🚀 Next Steps
1. **[Quick Setup](quick-setup.md)** - Get running in 5 minutes
2. **[Features Guide](features/markdown.md)** - Explore all capabilities
3. **[Deployment](deployment/docker.md)** - Go to production
---
Ready to Create Beautiful Docs?
Get started now and see your documentation transform!