miton

In development. The beta will be a downloadable desktop app with automatic updates. Access is not open yet.Request an invitation.

Guide · 7 min read

Export to PDF and DOCX

Export documents to PDF, DOCX, Markdown, or HTML with citations and footnotes preserved.

Product stage
Pre-release development
Last reviewed
2026-07-23
Successful result
The change is visible in the active project.

What this accomplishes

Export documents to PDF, DOCX, Markdown, or HTML with citations and footnotes preserved.

Export finished work without reformatting. PDF and DOCX keep headings, tables, footnotes, and bibliography; Markdown and HTML are available for other tools.

Citations are covered in citation system.

Current availability

This page documents behaviour verified in Miton development builds. Miton is still pre-release and is not publicly downloadable; invited beta users will receive a signed desktop build with automatic updates.

Before you start

  • A Miton development build, an active project and Writer open.
  • A connected model; keep the source material or existing document in the same project.

The four formats

The four formats are PDF, DOCX, Markdown, and HTML. The user picks the format at export time. The export preserves the document’s text, structure, citations, and footnotes.

PDF. Real PDF via the React PDF renderer. The PDF is searchable; the text is selectable; the tables are native PDF tables (not images); the citations are real footnote markers with the bibliography at the end; the headings are real PDF headings (the user can navigate the PDF via the table of contents in their PDF reader). The PDF is print-ready; the user can send it to a printer or upload it to a journal.

DOCX. Real DOCX via the docx library. The DOCX is editable in Word, Google Docs, Pages, and LibreOffice. The tables are native DOCX tables; the citations are Word fields; the headings are Word styles (so the user can navigate via the navigation pane in Word). The DOCX is revision-friendly; the user can track changes in Word after the export.

Markdown. Real Markdown with a citation extension. The Markdown is portable; the user can import it into Obsidian, Notion, Typora, or another Markdown tool. The citations are [@key] references; the bibliography is a list at the end. The headings are ATX-style; the user can convert to Pandoc with a single command.

HTML. Real HTML with embedded CSS. The HTML is self-contained; the user can open it in a browser, paste it into a CMS, or convert it to another format with Pandoc. The CSS is minimal and the user can override it with a custom stylesheet.

The intermediate representation (IR)

The export pipeline is in three stages. The first stage renders the document to an intermediate representation (IR). The IR is a JSON document with the text, structure, citations, and metadata. The IR is the same across all four formats.

The second stage compiles the IR to the target format (PDF, DOCX, Markdown, HTML). The compile stage is format-specific. A user who is unhappy with the PDF can switch to DOCX without re-rendering the document; the IR is cached.

The third stage writes the file to the user’s chosen location. The user can download the file, save the file to a specific folder, or copy the file to the clipboard (for HTML).

The IR is observable. The user can export the IR to JSON from the document menu. The IR is useful for debugging the export and for custom downstream pipelines.

The per-format configuration

The user can configure the export at the project level, the document level, or the export call. The configuration includes:

  • Page size — A4, US Letter, custom.
  • Margins — default, narrow, wide, custom.
  • Font — default, a specific font, a custom font.
  • Citation style — APA, MLA, Chicago, Harvard, custom.
  • Cover page — none, simple, custom.
  • Table of contents — none, automatic, custom.

The configuration is per format. The PDF can have a different page size than the DOCX; the Markdown can have a different citation style than the HTML. The configuration is preserved per project; the user can override the configuration at the document level for a one-off document.

The preview

The user can preview the export before committing. The preview is a side-by-side view: the document on the left, the rendered export on the right. The preview is for PDF and HTML; DOCX and Markdown are too complex to preview inline.

The preview is real-time. The preview updates as the user changes the export configuration. The user can scroll through the preview to verify the export; the user can cancel the export from the preview.

The preview is a CoW panel. The user can close the preview without losing the configuration. The user can reopen the preview from the export menu.

The export history

The export history is a list of the last 20 exports, with the format, the destination, and the timestamp. The export history is in the document menu; the user can click an entry to see the export’s configuration; the user can re-run the export with the same configuration.

The export history is per-document. A user who exports the same document multiple times has multiple entries in the history; the user can see the history of one document or the cross-document history.

The page size, margins, and font

The page size is the physical size of the page in the export. The default is A4 (210mm × 297mm). The user can pick US Letter (8.5“ × 11“), A3, A5, Legal, or a custom size. The custom size is in millimetres or inches.

The margins are the distance between the page edge and the text. The default is the publisher default (1“ top, 1“ right, 1“ bottom, 1“ left). The user can pick narrow (0.5“ on all sides), wide (1.5“ on all sides), or custom margins.

The font is the typeface used in the body text. The default is the user’s editor font. The user can pick a specific font (Times New Roman, Arial, Helvetica, etc.) or a custom font (the user provides the font file).

The cover page and table of contents

The cover page is the first page of the export. The default is no cover page. The user can pick a simple cover page (title, author, date) or a custom cover page (the user provides a template).

The table of contents is the list of headings in the document. The default is no table of contents. The user can pick an automatic table of contents (the export generates the table from the document’s headings) or a custom table of contents (the user provides the table).

What the export pipeline does not cover

The export pipeline does not cover:

  • Real-time export — the export runs on demand. The user clicks “Export”; the export runs; the export produces the file. The user cannot watch the export produce the file in real time.
  • Custom format plugins — the export supports PDF, DOCX, Markdown, and HTML. The user cannot add a custom format without modifying the export pipeline.
  • Batch export — the export produces one file at a time. The user can use a script to export multiple documents in a batch.

The export pipeline focuses on the four formats that cover the common cases. The less common cases are covered by the user’s existing tools (Pandoc, Calibre, etc.).

What success looks like

The four export formats are real exports, not screenshots. The PDF is print-ready. The DOCX is editable. The HTML is web-ready. The Markdown is structured.

Pick the format by the destination. Journal submission is PDF or DOCX. Web publication is HTML. Archiving is Markdown. Collaboration is DOCX.

The preview is your friend. Always preview PDF and HTML exports before committing. The DOCX and Markdown exports are too complex to preview inline; open the file in the target tool to verify.

The export history is the audit trail. The user can see every export, the destination, the timestamp. The user can re-run a previous export with the same configuration.

Common failures and recovery

  • Confirm the intended document and project are active.
  • Keep the original text when reviewing a model-proposed change.
  • Check the model connection and retry only the failed action, not the complete document.

Return to the Writer overview to choose the next document task.