Skip to content
YardMaths PDF

Extract the text from a PDF

Read, copy or download the words in a PDF.

Drop a PDF file here

or drag it here, or paste it.

Privacy: your files are opened and processed by your browser, on this device. They are never uploaded to YardMaths or anyone else, and they are gone when you close the tab.

How to get the text out of a PDF

  1. Choose the PDF, or drop it on the box. One file at a time.
  2. Optionally type the pages you want, such as 2-4, 9. Leave the box empty to read the whole document.
  3. Decide whether to mark where each page starts, and whether to join broken lines into paragraphs.
  4. Press Extract text. Your browser reads the text that is stored in the PDF; a preview appears under the result.
  5. Press Copy to clipboard, or download the text as a .txt file.

Why this tool runs in your browser

Documents full of text are often the sensitive ones: contracts, reports, medical letters, bank statements. An online extractor that uploads the file hands a full copy of those words to someone else’s server. Here your browser reads the PDF itself and shows you the text, so the words go from the file to your clipboard and nowhere else.

It also means you can pull text out of a very long PDF without hitting a page cap or waiting for an upload, and you can use the result straight away: the preview is editable text you can copy before you even download anything.

What this tool can and cannot read

A PDF can hold words in two ways. Most PDFs made from documents, web pages and exports keep real text, and this tool reads that text. A scan or a photo of a page is different: it holds only a picture, and a picture has no text to extract.

If you open a scan, the tool tells you that no text was found instead of giving you an empty file. Turning pictures of text into real text needs optical character recognition (OCR), which is a separate job from this one.

How the text is arranged

  • Lines come out top to bottom, and left to right inside a line, the way you read the page.
  • A blank line is added where the gap between two lines is larger than normal, so paragraphs stay apart.
  • Switching on “Join the lines of each paragraph” removes the line breaks inside a paragraph and mends words that were split with a hyphen at the end of a line.
  • Wide gaps inside a line, such as table columns, are kept as a few spaces so the cells do not run together.

Limits to know before you start

  • Only text that is really stored in the PDF can be extracted. Scans and photos of pages contain no text, so the tool will report that nothing was found.
  • The order of the text follows its position on the page. On pages with several columns, a line from one column can be followed by the matching line of the next, so very long multi-column pages may need a quick re-read.
  • Tables become lines of text with spaces between the cells. Bold, italics, fonts, colors and pictures are not kept.
  • A few PDFs store their letters with a broken font mapping, so the extracted text looks like gibberish even though the page looks fine. That is a problem in the file, and no text extractor can repair it.
  • Headers, footers and page numbers are part of the page, so they appear in the text on every page.
  • Password-protected PDFs cannot be read until the password is removed. You need to know it; this tool never tries to guess one.

PDF to Text FAQ

Why does PDF to text come out empty for my file?

Almost always because the PDF is a scan or a photo of a document. It contains a picture of the words, not the words, so there is nothing to extract. If you can select text with your mouse in a PDF viewer, this tool will read it; if you cannot, the file is an image.

Will the text keep the layout of tables and columns?

Not exactly. Text is returned in reading order with the gaps inside a line kept as spaces, so simple tables stay readable, but complex tables and multi-column pages can need tidying by hand. For exact layout, a PDF viewer is still the better tool.

Can I copy the text without downloading a file?

Yes. After extraction, the text appears in a box under the result with a Copy to clipboard button, so you can paste it straight into an email or a document. The .txt download is optional.

Does the extracted text go through a server?

No. The PDF is read by your browser, the text is built in the page, and the .txt file is created on your device. Nothing about your file is uploaded: the page only fetches its own code from this site.

What do the page markers do in the extracted text?

When the option is on, a line such as --- Page 3 --- is added before the text of each page, so you can tell where a page began. Turn it off if you want one continuous text with no markers.

Last updated . Free to use, no sign-up.