What happens when HTML, Markdown, CSV or plain text is converted to PDF?
The source is laid out onto fixed pages: text is wrapped and split at page boundaries, HTML and Markdown are rendered with the fonts available to the converter, and a CSV becomes a table that may need landscape pages or smaller type to fit its columns. The result is a real PDF with a text layer — selectable, searchable, with embedded fonts — but a static one: links survive, scripts and interactivity do not, and right-to-left text needs a converter that shapes Arabic correctly.
How to use Text to PDF
- Drop one or more text files.
- Keep or drop line breaks; set the page options.
- Click "Convert to PDF".
- Download each PDF or all as a ZIP.
Text to PDF features
- .txt, .log and .md as text; .rtf as text only (labelled)
- UTF-8 / UTF-16 read directly; legacy encodings decoded with a note
- Keep line breaks or re-flow into paragraphs
- Paper size, orientation, font size, margins, direction
- Page numbers and file-name header
- Arabic shaped right-to-left; Hindi conjuncts rendered
- Batch: one PDF per file
- Nothing uploaded
Text to PDF example
A server log
Input:
app.log — 3,400 lines, UTF-8Output:
app.pdf — 58 pages A4, lines kept, long lines wrapped, page numbers at the bottomFrequently asked questions about Text to PDF
Does it keep my line breaks?
By default yes — every line stays a line, which suits logs, code and poetry. Turn "Keep line breaks" off for prose that was hard-wrapped, so single breaks join into paragraphs while blank lines still separate them.
What about RTF files?
There is no maintained, permissively licensed RTF renderer for browsers, so RTF is read as text: paragraphs, tabs and Unicode characters are decoded, while fonts, colours, tables and pictures are dropped. The result tells you this. For formatted output, save the RTF as .docx and use Word to PDF.
My accented or Arabic characters are wrong.
The file is probably not UTF-8. Legacy encodings are decoded as Windows-1252 (or Windows-1256 on the Arabic site) and noted in the result; re-saving the file as UTF-8 in any editor fixes it for good.
Which fonts are used?
Cairo for Latin and Arabic and Noto Sans Devanagari for Hindi, embedded in the PDF so it looks the same everywhere. Arabic is shaped and set right-to-left.
Is my PDF uploaded to a server?
No. The file is opened and processed by your browser with WebAssembly and JavaScript; nothing is sent to Mutqan Soft or anyone else. Close the tab and the file is gone. Downloading the result needs a free account — no subscription, no payment.
Technical notes
Text is split into paragraphs on blank lines; with "Keep line breaks" each newline becomes a forced break inside the paragraph. The layout engine tokenises into words, measures them with the embedded faces (Cairo for Latin/Arabic, Noto Sans Devanagari), breaks lines greedily, orders bidi runs and draws each token through pdf-lib with fontkit shaping. RTF is decoded by a small tokenizer (groups, control words, \uN and \'hh escapes, the ansicpg code page) that keeps paragraph and tab structure only.
References
- ISO 32000-2:2020 — Document management — Portable document format — Part 2: PDF 2.0The current PDF standard: file structure, objects, pages, fonts, annotations, forms and encryption.
- HTML Living StandardThe HTML language, including named character references (entities) and the parsing rules browsers follow.
- CommonMark SpecThe unambiguous Markdown syntax specification most renderers follow.