Convert text to PDF online

Turn plain text into a neatly formatted PDF.

  1. 1Add files
0 files selected

Paste your text in the panel, or add .txt files here.

Quick answer

To convert a text file to PDF online, add a .txt file to PDF Lemon's Text to PDF tool, or paste your text, then choose page size, font size and margins. Click “Convert to PDF” and the text is wrapped and paginated automatically into a clean, searchable PDF document.

Good to know: Uses standard PDF fonts, which support Latin characters only. Other scripts are replaced with “?”.

Last updated · Convert to PDF

What does converting text to PDF do?

Converting text to PDF turns a plain .txt file, or text you paste, into a neatly laid-out PDF with page breaks, margins and a consistent font. Unlike a .txt file, a PDF looks the same on every device and prints properly.

It's handy for notes, logs, code snippets, transcripts and drafts that you want to share or archive in a format anyone can open.

How to convert text to PDF

  1. Add text

    Drop .txt files or paste text into the box.

  2. Format

    Choose page size, font size and margin.

  3. Convert

    Click “Convert to PDF”.

  4. Download

    Save your searchable PDF.

Which setting should you choose?

SettingChoose it when
Sans serifit's ordinary writing such as notes or letters.
Monospaceit's code, logs or anything that relies on columns lining up.
Font sizeyou need more on each page (smaller) or easier reading (larger).

How PDF Lemon converts text to PDF

PDF Lemon wraps your text to fit the page, breaks words that are too long for a line, and starts new pages automatically. You can choose a sans-serif font (Helvetica) or a monospaced one (Courier), a font size from 8 to 20 points, and A4 or US Letter paper. Margins are about 2 cm, with comfortable line spacing.

The text in the PDF is real text, so it can be selected and searched. The built-in PDF fonts cover Latin letters only, so characters from other scripts, such as Arabic, Chinese or Urdu, appear as question marks. PDF Lemon warns you before converting if that will happen.

Convert text to PDF on a phone or computer

Text to PDF is easy on a phone: copy text from a note, message or email, paste it into the box, and convert. On a computer, you can also drag in one or more .txt files, and they're combined in order. Long logs and transcripts work well, because pagination is automatic.

Tips for best results

  • Long lines wrap automatically, and new pages are added as needed.
  • The output text stays selectable and searchable.
  • Several .txt files are joined in the order shown, followed by any pasted text.

If something goes wrong

Some characters came out as “?”
This tool uses standard PDF fonts, which cover Latin letters only. Urdu, Arabic, Hindi, Chinese and similar scripts can't be drawn yet.
The Convert button is greyed out
Add a .txt file or paste some text first.

Other ways to turn text into a PDF

OptionHow it worksBest for
PDF Lemon Text to PDFPaste text or add .txt files, choose font and sizeQuick, clean PDFs on any device
Notepad on WindowsPrint, then Microsoft Print to PDFOne text file on Windows
TextEdit on MacFile, then Export as PDFMac users
Google Docs or WordPaste the text, format it, export as PDFHeadings, images or other scripts

Is this the right tool?

Text to PDF is a good fit for jobs like these:

  • Turn notes or logs into a shareable PDF
  • Print code or config files cleanly
  • Archive plain-text documents

Use something else if:

  • You need to go the other way, from PDF to plain textPDF to Text

Why use PDF Lemon

Automatic wrapping
Long lines wrap and pages break automatically.
Searchable output
Text in the PDF stays selectable and searchable.
Paste or upload
Works with .txt files or text pasted from anywhere.
Private
Your text never leaves your device.

Text to PDF at a glance

PriceFree, no sign-up, no watermark
InputText files (.txt)
OutputOne PDF file
Where it runsIn your browser; files are never uploaded
Works onWindows, macOS, Linux, ChromeOS, iPhone, Android
File limitsNo fixed limit; depends on your device's memory

Step-by-step guides

Guides that use Text to PDF, with steps for other apps too.

Text to PDF: questions and answers

How do I make a PDF from text I copied?

Paste the text into the box in Text to PDF, choose the font and page size, and click Convert to PDF.

Can I convert code or logs to PDF?

Yes. Choose the monospaced font, so columns and indentation line up the way they do in a code editor.

Will the PDF text be searchable?

Yes. The text is stored as real characters, so you can search it, select it and copy it.

Can I convert several .txt files into one PDF?

Yes. Add multiple files, set their order, and they're combined into one PDF, followed by any text you pasted.

Why do some characters show as question marks?

The standard PDF fonts cover Latin letters only. For other scripts, paste the text into Google Docs or Word and export a PDF from there.

How do I convert a TXT file to PDF?

Add the .txt file to Text to PDF, choose your page settings and click Convert to PDF.

Which characters are supported?

Latin-alphabet text (English and most Western European languages) is fully supported. Characters outside the standard PDF font set are replaced with “?”.

Is it safe to convert text to PDF on PDF Lemon?

Yes. PDF Lemon processes your files entirely inside your web browser using JavaScript. Your PDF is never uploaded to a server, so nobody else can see, store or copy it. When you close the tab, the file data is gone.

Is it free to convert TXT to PDF?

Yes, completely free. There is no sign-up, no watermark added to your output, no daily task limit and no file-size paywall. The only limit is your device's memory.

All convert to pdf tools