A modern, interactive documentation and guide platform built with Next.js. mdguide helps you create beautiful, searchable, step-by-step guides with progress tracking and an intuitive user experience.
Perfect for creating documentation sites, tutorials, courses, and step-by-step guides.
- π Step-by-Step Guides - Break down complex topics into manageable, trackable steps
- π Full-Text Search - Fast, client-side search powered by FlexSearch
- π Progress Tracking - Automatically track user progress through guides with local storage
- βοΈ MDX Support - Write guides in Markdown with full MDX support
- π¨ Syntax Highlighting - Beautiful code highlighting out of the box
- πΌοΈ Dynamic OG Images - Automatic Open Graph images for social media sharing
- π± Responsive Design - Mobile-first design built with Tailwind CSS 4
- π Dark Mode - Full dark mode support
- π€ LLM-Friendly - Automatic llms.txt generation for AI/LLM consumption
- π Type-Safe - Built with TypeScript for better developer experience
- β‘ Fast & Modern - Built on Next.js 16, React 19, and Tailwind CSS 4
The fastest way to get started:
-
Click "Use this template" button on GitHub to create your own repository
-
Clone your new repository:
git clone https://github.com/YOUR-USERNAME/YOUR-REPO-NAME.git cd YOUR-REPO-NAME -
Install dependencies:
npm install
-
Run the setup wizard:
npm run setup
This interactive wizard will:
- Configure your site name and branding
- Update package information
- Optionally delete example guides
- Optionally create a starter guide
- Optionally reinitialize git with clean history
-
Start the development server:
npm run dev
-
Open http://localhost:3000 to see your site!
Prefer to set up manually? See the SETUP.md guide for detailed instructions.
- SETUP.md - Complete setup and configuration guide
- CLAUDE.md - Detailed architecture and development guide
- Example Guides - Check
app/guides/for example content (marked withisExample: true)
- Framework: Next.js 16 with App Router
- UI: React 19
- Styling: Tailwind CSS 4
- Content: MDX with react-markdown
- Search: FlexSearch
- Language: TypeScript 5
mdguide/
βββ app/
β βββ [slug]/ # Dynamic route for guides
β βββ api/guides/ # Search API endpoint
β βββ components/ # React components
β βββ config/
β β βββ site.ts # π Main configuration file
β βββ guides/ # π Your guide content (MDX files)
β βββ hooks/ # React hooks
β βββ lib/guides/ # Guide processing logic
β βββ types/ # TypeScript types
βββ scripts/
β βββ setup.js # Interactive setup wizard
βββ SETUP.md # Setup documentation
βββ package.json
Create a new guide by adding a directory in app/guides/ with a page.mdx file:
Example: app/guides/my-guide/page.mdx
---
title: Getting Started
description: Learn the basics of mdguide
author: Your Name
date: 2025-10-31
tags: [beginner, tutorial]
published: true
---
Introduction to your guide...
## Step 1: First Step
Step content here. Each `##` heading creates a new step.
## Step 2: Second Step
More content with code examples:
```javascript
console.log("Hello, mdguide!");Wrap up your guide!
After creating your guide, it will be available at `http://localhost:3000/my-guide`
See [SETUP.md](SETUP.md) for detailed guide creation instructions.
## π€ llms.txt Support
mdguide automatically generates an `llms.txt` file from your guides, making your documentation easily accessible to AI and LLM tools.
### Configuration
Enable or disable llms.txt in **[app/config/site.ts](app/config/site.ts)**:
```typescript
llmsTxt: {
enabled: true, // Toggle llms.txt generation
includeStepContent: false, // Include full content or just titles
}
- Automatic Generation: All published guides are included in
/llms.txt - Configurable: Choose to include full step content or just titles
- Footer Link: A link appears in the footer when enabled
- LLM-Optimized: Follows the llms.txt specification
- Static Generation: Built at compile time for optimal performance
When enabled, your llms.txt file will be available at http://localhost:3000/llms.txt and includes:
- Guide titles and descriptions
- Author and date information
- Tags and metadata
- Step-by-step content (if enabled)
- Table of contents with anchor links
mdguide automatically generates beautiful Open Graph images for social media sharing.
- Automatic Generation: Homepage and every guide get custom OG images at build time
- Social Media Optimized: Perfect 1200x630px size for Twitter, Facebook, LinkedIn, etc.
- Dynamic Content: Shows guide title, site name, author, and step count
- Beautiful Design: Gradient background with professional typography
- Custom Image Support: Option to use your own custom image for the homepage
- Zero Configuration: Works out of the box with no setup required
When you share a URL, social media platforms automatically fetch the custom OG image:
- Homepage (
/): Shows site title and description - Guide pages (
/guide-name): Shows guide title, author, and metadata
Want to use your own custom OG image for the homepage?
- Place your image in the
public/directory (e.g.,public/og-image.png) - Update app/config/site.ts:
openGraph: { homepageImage: '/og-image.png', }
Guide pages will continue using dynamically generated images.
Want to customize the generated images?
- Homepage: Edit app/opengraph-image.tsx
- Guide pages: Edit app/[slug]/opengraph-image.tsx
You can:
- Change colors and gradients
- Adjust typography and layout
- Add your logo or branding
- Modify the visual style
npm run dev # Start development server
npm run build # Build for production
npm run start # Start production server
npm run lint # Run ESLint
npm run setup # Run interactive setup wizard- app/config/site.ts - Site name, description, branding
- app/guides/ - Your guide content (MDX files)
- app/components/ - UI components for customization
- package.json - Project metadata
Planned features for future releases:
- Export guides to PDF
- Multi-language support
- Advanced search filters
- Analytics and insights
- Community themes and plugins
Contributions are welcome! Whether it's bug fixes, new features, documentation improvements, or feedback:
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
Please ensure your code follows the existing style and includes appropriate documentation.
This project is open source and available under the MIT License.
mdguide is built with amazing open-source tools:
- Next.js - The React Framework
- Tailwind CSS - Utility-first CSS framework
- MDX - Markdown for the component era
- FlexSearch - Full-text search library
- gray-matter - YAML frontmatter parser
Built with β€οΈ using mdguide
β Star on GitHub β’ π Documentation β’ π Report Bug β’ π‘ Request Feature
