PDF to Text

Pull all the text out of a PDF as plain text you can copy or download. The PDF is read in this browser tab and is not uploaded.

How it works

Most PDFs made on a computer carry their words as real text, not as a picture of text. This tool reads that text out of every page and puts it back together as plain lines and paragraphs you can copy, search or paste anywhere.

The PDF is opened by pdf.js, the engine Firefox uses to show PDFs, right here in your browser. Nothing is uploaded, and it keeps working offline once the page has loaded.

A scanned PDF is different: each page is a photograph, so there is no text inside to read. The tool tells you when that is the case instead of handing back an empty file.

How to use it

  1. 1 Choose a PDF, or paste one with Ctrl+V.
  2. 2 Wait a moment while each page is read.
  3. 3 Turn on Label each page if you want to know where each passage came from.
  4. 4 Copy the text, or download it as a .txt file.

Good to know

  • Two-column layouts come out line by line across both columns. For a paper or a newsletter, check the order before you rely on it.
  • A scanned PDF has no text layer, so there is nothing to extract. Text recognition (OCR) is not something this site does.
  • A password-protected PDF needs its password removed first. Password-protect a PDF can take it off if you know it.
  • The PDF stays in your browser; nothing is uploaded.

Browser support

  • Chrome 94 and later
  • Firefox 93 and later
  • Safari 16.4 and later
  • Edge 94 and later

These are the oldest versions with everything the tool uses. They are worked out from the tool itself, so they change when it does.

Version numbers checked on 2026-09-04.

A PDF does not contain sentences, which is why extracting text means rebuilding them

Open a PDF in a text editor and you will not find the sentences you see on the page. A PDF is a set of drawing instructions. Each instruction says, in effect, put these glyphs in this font at this point on the page. The program that wrote the file decides how to cut the text into those instructions, and most cut it into short runs: a word, part of a word, a stretch of letters that share a font and spacing. Nothing in the file says that two runs belong to the same word, the same line or the same paragraph. That knowledge only exists in the picture the instructions draw.

So extraction is reconstruction. This tool asks pdf.js for every run on a page, with its text, its position and its size, and rebuilds the reading text from the geometry. Runs whose baselines sit within half a line height of each other are treated as one line; that tolerance is what keeps a raised superscript or a footnote marker on the line it belongs to instead of giving it a line of its own. Within a line, the runs are sorted left to right.

Spaces are the subtle part, because very often there are none. Many PDF writers never store a space character at all. They simply start the next word a little further along. Here a space is inserted when the gap between two runs is wider than about a third of a character in the preceding run, measured from that run’s own width. A narrower gap is kerning inside a word, which is why a word split across two runs comes back whole rather than as “Hel lo”. Lines are then stacked from the top of the page down, and when the distance between two baselines is more than one and a half line heights, a blank line marks a new paragraph.

This approach has a limit worth knowing about. Reading lines across the full width of the page is correct for letters, reports and most books, and wrong for anything set in columns. A two-column paper comes out with the first line of the left column followed by the first line of the right one. Recovering columns needs layout analysis: finding the vertical channel of white space between them and reading each column separately. That is a guess about the page, and a wrong guess scrambles a document that was fine, so the tool does not attempt it and says so instead.

The other limit is absolute. A scanned page is a photograph wrapped in a PDF, and a photograph has no runs to ask for. When every page comes back empty, the tool says the file is probably a scan rather than offering you an empty download. Recognising letters in a picture is a different job, optical character recognition, and an honest empty answer is better than a confident wrong one.

Frequently asked questions

How do I copy all the text out of a PDF?

Choose the PDF. Every page is read in a few seconds and the text appears in a box you can copy from, or download as a .txt file.

Why is the result empty?

The PDF is almost certainly a scan or a photo: each page is a picture, and a picture has no text inside it. Getting words out of a picture is called OCR, which this tool does not do.

Is my PDF uploaded?

No. The file is opened and read inside your browser tab. You can check with your browser’s network panel: nothing is sent when you pick a file.

Why are some lines in the wrong order?

A PDF stores text as pieces placed at positions on the page, not as a reading order. The tool rebuilds lines from top to bottom across the full width, which is right for ordinary documents but mixes up side-by-side columns.

Does it keep bold, headings or tables?

No. The output is plain text: words, line breaks and blank lines between paragraphs. Table cells come out as rows of words separated by spaces.

Related tools

Your files are processed on your device and are not uploaded. You can verify this in your browser’s developer tools under the Network tab.