Skip to content

Obsidian

Q: Does mdBook work with Obsidian? A: Yes, with two good workflows. mdBook: SUMMARY.md


Obsidian is a Markdown editor, mdBook is a static-site builder for Markdown. Keep your notes in an Obsidian vault, point mdBook at that content, and mind a few syntax/structure differences (links, callouts, book summary). Obsidian Help mdBook: Markdown mdBook: SUMMARY.md

Two interoperable setups

  1. Standards-first Markdown
    In Obsidian Settings → Files & Links, turn off “Use Wikilinks” so new links are standard [text](path.md); avoid Obsidian-only features or map them to mdBook plugins. This gives near-zero friction. Obsidian Forum (disable wikilinks) Obsidian Forum (Markdown links setting) mdBook: Markdown

  2. Obsidian-flavored Markdown with helpers
    Keep Obsidian features and add mdBook preprocessors:
    • Callouts > [!note]: use mdbook-callouts, or convert to mdbook-admonish fences.
    • Wikilinks [[Page]] and embeds ![[Note#Heading]]: try mdbook-obsidian (work-in-progress; subset supported).
    Review support and fall back to Markdown links where needed. mdbook-callouts mdbook-admonish mdbook-obsidian

What mdBook expects

  • Project shape: put content under src/; define order and nesting in SUMMARY.md. Without SUMMARY.md, mdBook won’t build a book. mdBook: SUMMARY.md
  • Markdown features: tables, task lists, footnotes, strikethrough work out of the box; raw HTML is passed through. mdBook: Markdown
  • Renderer config: enable math, extra JS/CSS, repo edit links, etc., in book.toml’s [output.html]. mdBook: Renderers

Quick-start from an Obsidian vault

  1. In Obsidian: Settings → Files & Links → disable wikilinks; prefer relative Markdown links. Keep callouts if you’ll add a preprocessor. Obsidian Forum Obsidian Help
  2. In your repo: src/ contains vault docs (or a selected subset), add a SUMMARY.md (or use mdbook-autosummary to generate one). mdBook: SUMMARY.md mdbook-autosummary
  3. In book.toml, wire any preprocessors you need:
[book]
title = "My Docs"
[output.html]
additional-css = ["custom.css"]
[preprocessor.callouts]
command = "mdbook-callouts"
# Or, if you prefer admonish fences instead of Obsidian callouts:
# [preprocessor.admonish]
# command = "mdbook-admonish"
# Experimental: Obsidian features (subset; check README)
# [preprocessor.obsidian]
# command = "mdbook-obsidian"

mdBook: Renderers mdbook-callouts mdbook-admonish mdbook-obsidian

Decision guide


Q: Does astro work with Obsidian?