Text, Markdown and HTML to PDF and DOCX
Write or paste text, Markdown or HTML, preview it, then export it to PDF or DOCX inside your browser.
Start the toolDescription
A tool for turning quick drafts and reports into documents you can share or print. It supports plain text, Markdown and HTML, with headings, lists, tables, links and text styling, and it handles Arabic and right-to-left writing. A live preview is shown before you export.
How to use it
- Choose the input type: text, Markdown or HTML, then type or open a file.
- Check the preview and set direction, page size, margins and font size.
- For a PDF press “Create PDF” and choose “Save as PDF” in the print dialog.
- For Word press “Create DOCX” and download the file.
How it works
Markdown is converted to HTML with the marked library, then all HTML is cleaned with DOMPurify, which removes scripts, forms, styles and images. The PDF is produced by your browser’s print engine, so text stays selectable and Arabic renders correctly, and you choose “Save as PDF” in the print dialog. DOCX is built with the docx library from the cleaned elements (headings, paragraphs, lists, tables, links). Images are not embedded and are replaced by their alt text, and the final look in Word may differ slightly from the preview.
Frequently asked questions
How is the PDF created?
By your browser’s print engine. Press “Create PDF” and choose “Save as PDF” in the print dialog. Text stays selectable and Arabic renders correctly.
Is my HTML sanitized?
Yes. Scripts, forms, styles and images are removed, and only http, https and mailto links are kept.
What does the DOCX contain?
Headings, paragraphs, bold and italic text, lists, tables, links and code blocks. Images are not embedded.