Written and tested by the MD Converter editorial team

Why Japanese Fonts Change or Break in Markdown PDFs

Diagnose changed Japanese fonts, garbled characters, and missing glyphs in Markdown PDFs, then verify a portable result.

A changed font and broken text are different problems

If Japanese text remains readable but looks different, the requested font was probably unavailable or replaced. Squares, question marks, or garbled strings point to missing glyphs or an encoding problem.

Provide a font stack with Japanese-capable alternatives and a generic family. Wait for web fonts to finish loading before printing; network restrictions, CSP, or offline use can prevent them from loading. A Latin-only font may cover English while Japanese falls back to another face.

Check kanji, kana, symbols, emoji, mathematical characters, and uncommon name characters. Save source Markdown as UTF-8 if it is already corrupted before rendering. Also verify bold weights because a missing weight can trigger synthetic bold or another fallback and change pagination.

A PDF viewer may list fonts and embedding status in document properties. Test the saved PDF on another device when appearance is important, and check the font license before embedding or distributing a commercial typeface.

Diagnose the symptom before changing CSS

Readable Japanese rendered in a different typeface is a fallback problem. Empty squares for a few characters indicate missing glyph coverage. Mojibake such as unrelated symbols appearing throughout the text usually begins with incorrect source encoding. A font that changes only after export may not have finished loading when printing started.

Create a one-page test document containing hiragana, katakana, common and uncommon kanji, Latin text, numbers, punctuation, bold text, and the exact character that fails. A small controlled sample makes it easier to identify whether the trigger is a glyph, font weight, or file encoding.

Build a safe Japanese font stack

List the preferred family first, followed by Japanese-capable system alternatives and finally a generic family. Do not put a Latin-only display font in charge of body text unless Japanese fallback has been tested. Keep body, emphasis, and headings to two or three necessary weights; every additional web-font file increases load time and creates another chance for printing before the font is ready.

Start from a standard sans-serif or serif setting. Export once with a white background and ordinary sizing. If that PDF works, restore the custom font, weight, and size one at a time. The first change that breaks output identifies the relevant layer.

Check source encoding

If text is already corrupted in the preview, inspect the .md file before investigating PDF output. Reopen a copy using its original encoding and save it as UTF-8. Avoid repairing mojibake character by character because some original information may already be lost.

Also inspect text copied from spreadsheets, legacy systems, and PDFs. Visually similar characters can use uncommon Unicode code points. Search for replacement characters and test names, addresses, circled numbers, arrows, measurement symbols, and old-form kanji explicitly.

Verify font loading and embedding

Wait until the preview typography stops changing before opening the print dialog. In a development environment, the browser Network panel can reveal blocked or failed font requests. Corporate proxies, content security policy, offline use, and privacy extensions can all prevent a remote font from loading.

After export, open the PDF in a viewer that reports document fonts. Look for the family name and whether it is embedded or subset embedded. Then test on a second device that does not have the custom font installed. If appearance remains stable, the PDF is portable enough for distribution.

Because font metrics affect pagination, recheck the Markdown PDF page-break workflow after changing the final typeface.

Japanese PDF preflight checklist

Font metrics affect line width and height, so a successful font fix can still move headings and images onto different pages. Treat typography and pagination as one final review step.

Frequently asked questions

Why are only emoji printed in black and white or as boxes?

Color emoji support differs between browsers, operating systems, and PDF destinations. Do not use emoji as the only carrier of meaning. Replace essential symbols with text or a licensed image when exact appearance matters.

Does changing the filename encoding fix garbled body text?

No. The filename and Markdown contents are separate. Open the source with the correct character encoding and save its contents as UTF-8. Renaming the file does not convert the bytes inside it.