Migrate from Mintlify

Migration•7 min read|
|

DocsLit is open source, built for AI agents, and designed so that a Mintlify project moves over in one command. The importer reads your docs.json (or legacy mint.json), converts every MDX page and component, rewrites links and assets, maps your navigation, branding and redirects, validates the result and writes a report of everything that needs a human.

Try DocsLit without converting

In a Mintlify repo that has a docs.json or mint.json and no docslit.json, run:

npx docslit dev npx docslit build

DocsLit converts the project in the background into node_modules/.cache/docslit/mintlify/ with the same converter as docslit import, then serves or builds from there. The cache stays inside your project and refuses paths that traverse symlinks. Build output goes to the dist/ folder of your repo.

dev converts again when you edit .mdx or .md files, docs.json, snippets or images. If a conversion fails, it keeps serving the last good version. Pass --no-compat to turn this off.

Use compatibility mode to try DocsLit and preview your site. To switch for good, run docslit import as described below. It writes a real DocsLit project and the full migration report.

Quick start

Run the importer

Point it at the folder that holds docs.json:

docslit import {{MINTLIFY_DIR}}

DocsLit detects Mintlify from docs.json or mint.json, converts the project into {{MINTLIFY_DIR}}-docslit/, and never touches the source. Use --out to choose another folder.

Read the report

The command prints a summary and writes MIGRATION.md into the output. It lists every error, warning and note with a file, a line, what the importer did instead and how to fix it. See the import reference.

Preview and validate
cd {{MINTLIFY_DIR}}-docslit docslit dev docslit validate

Check the pages that the report flagged, and run docslit validate until it is clean.

Publish

Delete MIGRATION.md when you are done, then build and host the site anywhere, or publish it with DocsLit Cloud.

Add `--dry-run` to convert everything in memory and print the report. Nothing is written, so you can see how much work the move is before you start. docslit import {{MINTLIFY_DIR}} --dry-run

Prefer to have an agent drive the move page by page? See Migrate with your AI agent.

What is converted

Area Result
Pages Every .mdx page becomes Markdown with wc-* components. Imports and exports are removed, JSX props become attributes, and links and assets are rewritten.
Components All Mintlify components are converted: callouts, accordions, cards, tabs, steps, code groups, request and response examples, fields, frames, badges, expandables, updates, tooltips, tree, color, view, prompt, panels, icons, embeds and conditional content. See the full component mapping.
Code blocks Mintlify fence options ({1,3-5}, focus, lines, wrap, expandable, icon, nocopy, and the [!code ++] notation) work as they are. See Code blocks.
Snippets /snippets/*.mdx files become reusable includes in docs/_reusables/, with props mapped to {{prop}} placeholders. Exported variables become attributes.
Navigation Tabs, groups, nested groups, anchors, dropdowns, products and external page links become tabs, sidebar and anchors.
Branding Name, description, logo (light and dark), favicon, colors and fonts become a theme with your brand colors on top.
Site chrome Navbar links and the primary button, footer socials and columns, the banner, redirects, SEO meta tags, the contextual menu and analytics.
API An OpenAPI spec is copied in and API pages are generated, so the spec keeps working.
Frontmatter sidebarTitle, tag, mode, hidden, noindex, icon, deprecated and the other page keys are mapped. See the key changes.

Your look

Mintlify sites move to the peppermint theme, which has the same airy, product-docs feel, with your brand colors, fonts and logo applied on top. Choose another look at import time, or skip theming:

docslit import {{MINTLIFY_DIR}} --theme ledger docslit import {{MINTLIFY_DIR}} --no-theme

With --no-theme your brand colors are still applied. You can switch later with docslit theme use. See Themes.

Configuration mapping

docs.json keys become docslit.json keys. Run the importer with --json to see the exact mapping for your project.

Mintlify docs.json DocsLit docslit.json
name, description, favicon name, description, favicon
logo (light, dark, href) logo with the same keys
colors (primary, light, dark) theme colors: accent in light and dark mode, plus a derived link color
fonts (body and heading) theme.fonts.sans and theme.fonts.heading, plus a head link for Google fonts
appearance (default, strict) theme.appearance and theme.strict. See Palettes and brand colors.
icons.library icons.library
navigation.tabs, groups, pages, products tabs and sidebar. See Tabs and anchors.
navigation.global.anchors, anchors anchors
navigation.versions tabs, one per version, or only the default version with --versions latest
navbar.links, navbar.primary navbar.links and navbar.primary, including github and discord types
footer.socials, footer.links footer.socials and footer.columns
banner announcement
redirects redirects
seo.metatags head meta tags
contextual.options contextual. See Contextual menu.
integrations (ga4, posthog, plausible, fathom) analytics. gtm becomes a script in head.
openapi, api openapi and playground settings

Page frontmatter changes as well:

Mintlify page key DocsLit frontmatter
sidebarTitle sidebar_title
tag badge. Frontmatter tag means the page-header category in DocsLit.
mode: wide, custom, frame, center layout with the same values
hideFooterPagination hide_nav
icon and iconType icon
hidden, noindex, deprecated, contextual The same keys
searchable: false searchable: false

What changes and why

  • Callouts have no forced title. <Note> becomes <wc-callout type="note">, because the icon already says what it is. Add a title when you want a heading.
  • Steps number themselves. The importer no longer writes step numbers. It only writes n when your source set stepNumber.
  • Tabs sync by default in Mintlify. The importer adds sync="mintlify" to every Tabs so readers keep their choice across the site. Pass sync={false} in your source to opt out.
  • Icons are resolved at build time. Lucide and Font Awesome names, fa-brands fa-github classes and emoji pass through unchanged. See Icons.
  • Hidden pages are built. A page with hidden: true is kept, built and reachable, but left out of the sidebar, search and sitemap.
  • A new look. Colors and fonts become a theme, not CSS variables. Google font families from fonts get a <link> in head. Custom CSS written against Mintlify's --mint-* variables does not carry over, so restyle with design tokens. Selectors that use Mintlify's ids, classes and data-component-part hooks keep working in the file set by css. See Custom CSS.

Known limits

The importer is honest about what it cannot convert. Each of these appears in MIGRATION.md with a fix.

  • Versions become tabs. DocsLit versions are git branches. The default import makes one tab per Mintlify version in a single site. To get a version selector, split each version onto its own branch and configure versions. See Versioning.
  • Languages. The first language is converted, and the pages of the others are kept as hidden pages. DocsLit uses a docs.<locale>/ folder per language. See Internationalization.
  • Pattern redirects. Patterns such as /old/:slug* are carried over. A rule that DocsLit rejects is skipped and reported as redirect-invalid. Add one explicit redirect per path for those. GitHub Pages ignores pattern redirects. See Redirects.
  • Custom JavaScript and React components. A component with no DocsLit equivalent stays in the page inside a warning callout titled "Unconverted component", never dropped. Replace it with Markdown, a reusable snippet, or a custom component.
  • Analytics and integrations without a preset (such as Intercom) are listed. Paste the vendor's snippet into head.
  • Content gated by login, roles or groups cannot exist on a static site. It is removed and reported.
  • Contextual menu options for Cursor, Devin, Grok, AI Studio and the download actions are dropped. See Contextual menu for the supported options.
  • Search prompt, background images, directory and drilldown navigation, and the boost page key have no equivalent. Each is listed in the report.

After the move

  • Run docslit lint for a quality pass over descriptions, headings and alt text.
  • Run docslit agents init to add an AGENTS.md and MCP configuration, so agents can maintain the docs. See Agent setup.
  • Every published DocsLit site serves Markdown, llms.txt and an MCP endpoint without extra setup. See Reading docs as an agent.

Next steps