Home › File & PDF Tools › TXT to PDF Converter
TXT to PDF Converter
This free TXT to PDF converter turns plain text into a proper, paginated PDF. Type or paste your text — or open a .txt file from your device — then choose the font, size, margins and page size, and download a clean document with wrapped lines and page breaks in the right places. The conversion happens entirely in your browser, so your words are never uploaded anywhere.
Nothing leaves your device. Your text is turned into a PDF locally in your browser — no upload, no server, no copy kept anywhere.
How to use this converter
- Type or paste your text into the big box — or drop a .txt file onto the drop box to load a file's contents instead.
- Choose the font, font size, page size and margins. Add a title line if the document needs one.
- Keep page numbers ticked if you want a "Page X of Y" footer, and set the output file name.
- Press Create PDF. The summary tells you how many pages were produced, and the PDF downloads.
How it works
A .txt file is the simplest document there is: characters and line breaks, nothing else. A PDF page, by contrast, needs every line placed at an exact position. This converter bridges the gap with the jsPDF library, stored on this website and run in your browser. It measures your chosen font against the printable width of the page — the page width minus the two side margins — and breaks each of your paragraphs into lines that fit, a job called word wrapping:
Your own line breaks are always respected: when you pressed Enter, the PDF starts a new line too, and a blank line in your text stays blank in the PDF. Wrapped lines use a line height of 1.4 times the font size, the comfortable spacing of a typed letter, and when a page fills up the text simply continues at the top of the next page. The pagination is worked out before anything is drawn, which is how the footer can honestly say "Page 2 of 5" — the tool already knows there will be five pages.
| Setting | Effect on your document |
|---|---|
| Font size 10 pt | More words per page; best for long documents |
| Font size 14 pt | Large, easy-to-read pages; more pages overall |
| Narrow margins | Longer lines, fewer pages |
| Wide margins | Shorter lines, room for handwritten notes |
| Courier font | Every character the same width — space-aligned columns survive |
| Times font | The classic letter and book look |
The one thing plain text cannot give you is styling of its own. A .txt file does not record bold, italics, headings or colours, so there is nothing for any converter to preserve — the words and line breaks are the whole content. That is also the format's strength: a text file written thirty years ago opens perfectly today, and the PDF you make from it here will print the same on every machine. If your text was copied from a table or a statement where columns were lined up with spaces, pick Courier before converting — in a monospaced font every character takes the same width, so your columns stay columns.
Everything runs on your device. The text is measured, wrapped and written into the PDF inside your browser tab; nothing is uploaded, and closing the tab clears the text for good.
Worked example
A student has a short set of meeting notes typed in Notepad — a heading, three numbered points and a closing line — and needs a PDF for the class group.
Step 1: She pastes the notes into the box (the box above is pre-filled with exactly this example).
Step 2: She keeps the defaults: Helvetica, 12 pt, A4, normal margins, page numbers on, and leaves the title empty.
Step 3: She presses Create PDF.
Step 4: The summary reports 1 page, and text-document.pdf downloads.
The result is a single tidy A4 page — her line breaks kept, the numbered points in order, and "Page 1 of 1" at the bottom. With a longer file — say a 3,000-word essay — the same steps would produce several pages, wrapped and numbered the same way.
FAQ
Is my text uploaded to a server?
No. The text you type or open is turned into a PDF entirely in your browser, using the jsPDF library stored on this website. Nothing you write is sent anywhere, so private notes, letters and drafts stay on your own device.
How does the tool lay out my text?
Your text is wrapped to fit the page width you choose, flowing from page to page until it runs out — like a word processor, but simpler. Line breaks you pressed Enter on are kept as new lines, blank lines stay blank, and long lines that would run off the paper are wrapped automatically. Pick a larger font size or narrower margins if you want fewer, fuller pages.
Which page size should I choose, A4 or Letter?
Choose A4 if you print in India or almost anywhere outside North America — A4 (210 × 297 mm) is the standard there. Choose Letter (8.5 × 11 inches) for printing in the United States or Canada. The text is laid out fresh for the size you pick, so either choice fills its pages properly.
Can I add a title and page numbers?
Yes. Type anything in the title box and it prints in a larger bold font at the top of the first page. Tick the page numbers box and every page gets a 'Page X of Y' footer at the bottom centre. Both are optional — leave the title empty and the box unticked for a plain document.
Why does my text look different in the PDF?
A .txt file holds words only — no fonts, bold, italics or colours — so there is nothing to preserve except the words themselves and your line breaks. This tool sets the words in the font, size and margins you pick on the page. If you pasted text that was aligned with spaces, choose the Courier font: it is monospaced, so columns lined up with spaces stay lined up.