Skip to content

📄 PDF Text Extractor

Drag and drop a PDF to extract text page by page. Copy or download as .txt. Everything runs in your browser.

100% Free No signup Browser-only 5 languages Dark mode

🔒 About Privacy

⚠ Image-based scanned PDFs cannot be extracted (OCR required). Only PDFs with a text layer are supported.

📂

Drag & drop a PDF, or click to select

📖 Where people get stuck

Uses pdf.js to pull the text layer out of a PDF, page by page. Everything runs in the browser and the file is never uploaded. What comes out is only what was written as characters: paragraphs, tables and headings do not exist in the PDF to begin with, because a PDF is a set of drawing instructions that place glyphs at coordinates, not a structured document format.

Case What happens What to do
The extracted text comes out in the wrong order The body of a PDF is a list of instructions saying draw this glyph at this position, and nothing guarantees the reading order. A two-column paper interleaves the left and right columns; a table loses its rules and leaves the cell contents strung out in a row. Headers and page numbers land in the middle of the prose. This is not a failed extraction — the ordering simply is not in the file. Start by turning on Preserve layout: characters with a similar Y coordinate are grouped back into lines, so even a multi-column page is at least correct line by line. Then split the columns by eye. If you actually want tables, switch to a table-extraction approach instead of text extraction — Tabula, Camelot or pdftotext -layout. Misaligned columns usually mean the width estimate failed, so rendering in a monospaced font and cutting at column positions often recovers them.
The text is garbled, or copies out as different characters A PDF draws text by glyph index inside an embedded font. Without the mapping table that turns those indices back into Unicode (the ToUnicode CMap), no extractor can recover the real characters. It goes missing most often when the producing application subsets the font, and the classic symptom is that the page reads perfectly on screen but copies out as nonsense. Older Japanese PDFs and files exported from DTP software are frequent offenders. There is nothing the extractor can do. If you can regenerate the file, re-embedding the font on export is the only real fix. When all you have is the finished PDF, rendering the pages to images and running OCR is in practice the fastest route (OCR tool). You can tell within a few lines of output whether the mapping is broken, so always check page one before processing the whole document.
The extraction returns zero characters A scanned document, or a photo turned into a PDF on a phone, is one image per page with no text layer at all. It is easy to miss because the characters are plainly visible, but the file content is a photograph. Government handouts, scanned contracts and digitised paper archives are almost always of this kind. Send it through OCR. The OCR tool uses Tesseract for Japanese and English and, like this page, does not hand your file to a third party. Telling them apart is easy: if the character count is tiny relative to the page count — a handful of characters per page or fewer — it is a scan. Mixed files, with text pages and scanned pages in the same document, are common too, so read the per-page character counts and send only the zero-character pages to OCR.

Being able to extract something is not the same as being allowed to use it. A PDF can carry a permission flag that forbids content extraction, but that flag is a convention honoured voluntarily by viewers, not a technical protection — pdf.js and most other implementations simply ignore it. Nor can you read the absence of the flag as permission. Whether you may redistribute or adapt the text is decided by the copyright and licence of the original document, and nothing else. Note also that everything on this page runs in your browser, so a confidential PDF never leaves your machine — but that guarantee ends the moment you paste the extracted text into some other service.

📖 How to Use

  1. 1
    Load a PDF
    Drag and drop or click to select a PDF. pdf.js extracts text automatically.
  2. 2
    Adjust options
    Toggle layout preservation and page numbers via checkboxes; the output updates.
  3. 3
    Copy or download
    Copy all text to clipboard, or download as a .txt file.

❓ Frequently Asked Questions

Can I extract text from scanned PDFs?
No. Image-only PDFs require OCR. Only PDFs that contain a text layer are supported.
Is the PDF uploaded to your server?
No. pdf.js extracts text in your browser. The file never leaves your device.
What is the difference between preserving layout or not?
When enabled, line breaks and spaces are kept. When disabled, the output is joined into readable paragraphs.
🐛 Found a bug or issue with this tool?

Free to use, no signup. Even just the steps to reproduce are helpful. Reports go directly to the operator and help us fix issues.

* Browser info (UA / screen / language / URL) is sent automatically to help reproduce the issue