Moving from Mintlify to open-source, self-hosted docs
How to migrate from Mintlify to an open-source docs site you host yourself with docslit import: dry run, what converts, the report, and where to deploy.
You have a Mintlify project with a few hundred MDX pages, and you'd like the source, the build and the hosting to live under your control. This post walks through how to migrate from Mintlify to DocsLit, an open-source (Apache-2.0) docs generator, using the importer that ships with the CLI.
Why teams move off a hosted docs platform
Mintlify is a polished product, and for many teams it's the right call. A managed platform with a web editor and hosting handled for you saves real time, and if that's what you want, stay.
The teams we hear from move for other reasons:
- Ownership. They want the docs build to be something they can run, read and fork, with the output hosted wherever their other infrastructure lives.
- Static output.
docslit buildwrites plain HTML todist/. You can put that folder on any static host. - Weight. By DocsLit's own measurements, the client JavaScript is 16 KB gzipped, with no React runtime or hydration step. Those are our numbers for our own build, so measure your own pages before and after.
- Agent access. Published sites serve Markdown,
llms.txtand an MCP endpoint without extra setup. We cover how that works in how AI agents read your docs.
The tradeoff is that you take on more of the operation yourself, unless you choose a managed host. We'll get to that at the end.
Run the importer, dry run first
Point docslit import at the folder that holds your docs.json (the legacy mint.json works too). Start with a dry run. It converts everything in memory and prints the report without writing a file, so you can size the job before you commit to it.
docslit import ./my-mintlify-docs --dry-run
When the numbers look reasonable, run it for real:
docslit import ./my-mintlify-docs --out ./docs-site
The importer never touches your source folder, and re-running it on the same input produces the same files. If the output folder isn't empty, it refuses unless you pass --force. For a machine-readable report, add --json.
What converts
- Pages. Every
.mdxpage becomes Markdown. Imports and exports are removed, JSX props become attributes, and links and assets are rewritten. - Components. Callouts, accordions, cards, tabs, steps, code groups, fields and the rest map to DocsLit's
wc-*web components. The full list is in the component mapping. - Navigation. Tabs, groups, anchors and dropdowns become
tabs,sidebarandanchorsindocslit.json. - Branding. Name, logo, favicon, colors and fonts become a theme. Mintlify projects get the
pepperminttheme by default, with your brand colors on top. Use--themeto pick another, or--no-themeto skip it. - Redirects, SEO meta tags, the navbar, footer and analytics presets, plus your OpenAPI spec.
Read MIGRATION.md before you fix anything
The importer writes a MIGRATION.md into the output folder. It groups every item as Must fix, Review or For your information, and each one gives a file, a line, what the importer did instead and how to fix it.
The part we care most about: nothing is silently dropped. A component with no DocsLit equivalent, such as a custom React chart, stays in the page inside a warning callout titled "Unconverted component". You can search for it, and it can't ship by accident.
Some things really do need a human:
- Versions become one tab each. DocsLit versions are git branches, so a real version selector means splitting them out.
- Languages: only the first is converted, and the others are kept as hidden pages.
- Wildcard redirects such as
/old/:slug*are skipped. Add one explicit redirect per path. - Login-gated content is removed, because a static site has no login.
- Custom CSS written against Mintlify's class names or variables doesn't carry over. Restyle with design tokens.
The import reference lists every issue code and the usual fix. If you'd rather have a coding agent work through the list, the docs also cover docslit agents print migrate and the convert_mdx MCP tool for one page at a time.
Preview and validate the result
The importer already validates its own output, but you should look at it. Open the site, check the first page of every tab, and compare a few pages that use heavy components:
cd docs-site
docslit dev
docslit validate --strict
docslit lint
docslit validate checks correctness, and docslit lint is a quality pass over things like descriptions, headings and alt text. Work through the report, re-run validate, and delete MIGRATION.md when it's empty.
Host it anywhere, or let us host it
Set "url" in docslit.json so the sitemap and llms.txt get absolute URLs, then build:
docslit build
Upload dist/ to any static host. The docs include steps for Vercel and Netlify, and we compare options in where to host static docs.
If you don't want to run hosting, DocsLit Cloud is the managed option. It's in early access and priced on request: we set up your account by hand, and then you publish from CI with a DOCSLIT_TOKEN environment variable and docslit publish.
To try the importer on your own project, start with the Mintlify migration guide and a --dry-run. If the importer misses something in your project, open an issue on GitHub so it gets fixed for everyone.