Extract the text from a PDF

Pull the words out of a PDF so you can quote, search, translate or reuse them. Copy them straight to your clipboard or save them as a plain text file.

Drop a PDF here, or click to browse

Text is read locally by your browser.

    Layout
    Load a PDF to see its page count.

    Nothing is uploaded. This page opens and rewrites your PDF using your own browser's memory, then shows you the finished pages so you can check them before you download.


    Using PDF to text, step by step

    1. Drop a PDF onto the box above.
    2. Choose whether to mark each page with a heading — useful for long documents, noise for short ones.
    3. Press Extract text. The words appear in a box you can read and edit.
    4. Copy the text to your clipboard, or download it as a .txt file.

    Two kinds of PDF, and only one of them has text

    Every PDF falls into one of two categories, and knowing which you have explains almost every question people ask about extraction.

    A digital PDF was created by software — exported from Word, printed to PDF from a browser, generated by an accounting system. It contains real text: character codes, font references and coordinates. Extraction from these is fast, exact and lossless, because the words were never anything but words.

    A scanned PDF is a photograph of paper wrapped in a PDF container. To your eye it looks like a document; to software it is a picture with no text in it whatsoever. There is nothing to extract, and no tool that reads text layers can invent one. Optical character recognition can look at the pixels and guess at the letters, but that is pattern recognition with an error rate, not extraction.

    The test takes two seconds: open the PDF and try to drag-select a word. If it highlights, you have a digital PDF and this tool will work perfectly. If nothing happens, you have a scan.

    Why the output needs tidying

    A PDF has no concept of a paragraph, a heading or a column. What it stores is closer to instructions for a printing press: put this string of glyphs at this coordinate in this font. The visual structure you perceive is an emergent property of where things happen to sit on the page, and rebuilding it afterwards is genuinely difficult.

    In practice, plain single-column prose extracts almost perfectly. Documents with two columns can interleave, because text on the left and right of the same line may be adjacent in the file. Headers, footers and page numbers appear in the flow, since nothing marks them as furniture. Tables lose their grid. Hyphenated words broken across lines stay broken.

    The join broken lines option helps with the most common of these, merging lines that clearly continue a sentence into flowing paragraphs. It is a heuristic, not magic, so read the result before relying on it.

    What extraction is good for

    Quoting accurately from a report without retyping. Feeding a document into a translator or a summariser. Searching a file whose own search is unreliable. Getting a reference list out of a paper. Recovering the wording of a contract into a document you can actually edit. Checking a word count. Making the content of a PDF accessible to a screen reader that struggles with the original layout.

    If the reverse is what you need — text going into a PDF rather than out of one — the natural routes are exporting to PDF from your word processor, or converting images to PDF and then merging them into a pack.

    Frequently asked questions

    I got nothing back, or only a few stray characters.

    Your PDF is almost certainly a scan — a photograph of a page rather than a page of text. There is no text layer to extract, only pixels. Reading those requires optical character recognition, which is a different kind of tool. You can tell which sort you have by opening the PDF and trying to select a word with your mouse: if nothing highlights, there is no text in the file.

    Why is the spacing and line-breaking odd?

    Because a PDF does not store paragraphs. It stores fragments of text at absolute positions on a page, and the reading order has to be reconstructed. Straightforward single-column documents come out cleanly. Multi-column layouts, tables, sidebars and footnotes are where it gets untidy, because visually adjacent text may be far apart in the file.

    Are tables preserved?

    The words are, the structure is not. A table becomes a run of cell contents without its rows and columns, because the grid you see is drawn separately from the text sitting inside it. For data you actually need to work with, extracting to text is the wrong route — look for the original spreadsheet.

    Can I extract from just one section?

    Pull out the pages you want first with Extract pages, then run the result through here. That is usually faster than extracting everything and deleting the parts you did not want.

    Is my document uploaded to do this?

    No. The text is extracted by PDF.js running in this browser tab, using the same engine Firefox uses to display PDFs. Nothing is sent anywhere, which also means you can extract from confidential documents without a policy problem.


    Related PDF tools

    Most jobs need two or three steps. These pair well with PDF to text.