Overview
Publishing and Deployment Summary
Publishing and deployment involves preparing your documentation for production, generating social share cards, and exporting content into portable offline formats such as EPUB. You can build and deploy your documentation site to standard hosting platforms, automatically generate Open Graph (OG) social preview images for every page, and package your documentation into downloadable e-books.
Social Cards and Open Graph Images
Open Graph Image Overview
Documentation pages can automatically generate Open Graph (OG) images to provide rich visual previews when shared on social media platforms and messaging apps.
Image Generation Options
The software supports rendering dynamic social cards with customizable titles, descriptions, branding, site names, and accent colors.
Note
Social images are generated at a standard resolution of 1200x630 pixels.
Exporting Documentation to EPUB
EPUB Export Overview
You can export your entire documentation site into an EPUB e-book format for offline reading.
Exporting Steps
- Add the EPUB export dependency to your project:
pnpm add fumadocs-epub - Enable
includeProcessedMarkdown: truein your documentation collection configuration. - Scaffold the export endpoint for your application framework. For Next.js projects, set an
EXPORT_SECRETenvironment variable to secure the export endpoint. - Run your project's production build command (for example,
pnpm build). - Start your production server and keep it running in the background.
- Run the export command via the command line tool, specifying your framework:
fumadocs export epub --framework next
Supported Frameworks for EPUB Export
The CLI export command supports the following frameworks via the --framework flag:
| Framework Identifier | Description |
|---|---|
next | Next.js App Router projects |
tanstack-start | TanStack Start projects |
react-router | React Router projects |
waku | Waku server components framework |
Important
When exporting from a Next.js project, make sure the production server is running locally and the EXPORT_SECRET environment variable matches on both the server and your export command environment.