Documenting your homelab is one of those tasks everyone puts off — until you need to remember why you configured that VLAN or where the WireGuard peer config lives. A proper documentation site solves this, and Docusaurus is an excellent choice for homelabbers who prefer static sites, Git workflows, and Markdown-driven content.
Why Docusaurus for Homelab Documentation
Several tools exist for homelab documentation. Here is how they compare:
| Feature | Docusaurus | BookStack | Outline | Wiki.js |
|---|---|---|---|---|
| Content format | Markdown/MDX | WYSIWYG | Markdown | Markdown |
| Storage | Git repo | MySQL/MariaDB | PostgreSQL | PostgreSQL |
| Versioning | Built-in | Manual | Manual | Plugin |
| Search | Local or Algolia | Built-in | Built-in | Elasticsearch |
| Deployment | Static site (CDN/docker) | Docker + DB | Docker + DB | Docker + DB |
| Customization | React/JSX | Templating | Limited | JS |
Docusaurus wins on portability — your docs are plain Markdown files in a Git repo. No database, no WYSIWYG lock-in. You can edit in any editor, version with Git tags, and deploy to anything from a Docker container to Cloudflare Pages or GitHub Pages.
Installation and Project Scaffolding
You need Node.js 18 or later and a Git repository.
npx create-docusaurus@latest my-lab-docs classic
cd my-lab-docs && npx docusaurus start
This creates the project skeleton:
my-lab-docs/
├── blog/ # Optional blog section
├── docs/ # Your documentation (Markdown)
│ ├── intro.md
│ └── tutorial/
├── src/
│ ├── components/ # Custom React components
│ ├── css/ # Custom styles
│ └── pages/ # Standalone pages
├── static/ # Static assets (images, files)
├── docusaurus.config.js # Main configuration
├── sidebars.js # Sidebar structure
├── package.json
└── Dockerfile # You will add this
Run npx docusaurus start to preview at http://localhost:3000.
Configuration and Customization
Edit docusaurus.config.js to set your site metadata:
|
|
Custom CSS
Override the Docusaurus theme colors in src/css/custom.css:
|
|
Docusaurus respects the system color scheme by default and switches seamlessly between light and dark modes.
Writing Documentation — Sidebars and MDX
Sidebar Configuration
You have two options: auto-generated or manual sidebars.
Auto-generated (simplest — just use the file structure):
|
|
Manual (full control):
|
|
MDX Features for Homelab Docs
Docusaurus uses MDX — Markdown with inline JSX. Useful features for technical docs:
Admonitions:
|
|
Tabs for multi-platform configs:
Docusaurus supports MDX tabs natively:
|
|
Mermaid diagrams for network topology:
|
|
Adding Search
For a self-hosted homelab docs site, the local search plugin works best:
|
|
Then add it to docusaurus.config.js:
|
|
For public documentation, Algolia DocSearch is also available (free for open-source projects).
Versioning Your Documentation
Docusaurus versioning lets you tag releases of your docs to match infrastructure changes:
|
|
This creates versioned_docs/version-1.0/ and versioned_docs/version-2.0/. Readers can switch versions from a dropdown in the navbar.
Use versioning when your infrastructure goes through significant changes — for example, after migrating from RouterOS 6 to 7, or upgrading Proxmox to a new major release. Each version retains its own sidebar configuration in versioned_sidebars/.
Docker Deployment
A multi-stage Docker build produces a small, production-ready image:
Dockerfile
|
|
nginx.conf
|
|
docker-compose.yml
|
|
Build and Deploy
|
|
The site is now running behind Traefik with automatic Let’s Encrypt SSL.
GitOps Workflow
The real power of Docusaurus comes from treating your docs as code.
Gitea Actions Example
|
|
With this workflow, every push to main automatically rebuilds and redeploys the docs site. No manual steps, no SSH sessions — just git push.
Cloudflare Pages Alternative
If you prefer a managed CDN, connect your Git repo to Cloudflare Pages. Set the build command to npm run build and the output directory to build. Cloudflare handles SSL, edge caching, and global distribution automatically with zero infrastructure to maintain.
Conclusion
Docusaurus gives you a professional documentation site with zero runtime dependencies. No database, no PHP, no WYSIWYG editor to fight with. Just Markdown files in a Git repo, with built-in search, versioning, and a clean dark-mode theme that your eyes will thank you for.
For homelab environments where your infrastructure evolves frequently, Docusaurus excels because it forces you into a Git-based workflow — every update is tracked, reviewable, and deployable through CI/CD. Combined with Docker for self-hosting or Cloudflare Pages for global delivery, it is one of the lowest-maintenance documentation tools you can run.
For more details, see the official Docusaurus documentation.