FreePDF logoFreePDF

Can't Copy Text From a PDF? Four Reasons and Fixes

By the FreePDF team ·

You drag across a paragraph and nothing highlights. Or it highlights but Copy is greyed out. Or you paste and out comes a string of symbols that looks like a corrupted file. Or the words arrive intact but every line ends in a hard return. Each of those has a different cause, and a different fix.

Work out which problem you have

  • Clicking selects the whole page as one block, or nothing at all: the page is an image, usually a scan.
  • Text highlights but Copy is greyed out, or the viewer says copying isn't allowed: the file has permission restrictions. Document properties, under Security, will usually say so.
  • Copying works, but the paste is gibberish: a font problem inside the PDF.
  • The paste is correct but the formatting is a mess.

It's a scanned page

A scanner produces a photo of the paper. You can read the words, but the file only knows about pixels, so there's nothing to select or search. OCR reads the letters off the image and adds an invisible text layer behind each page. The page looks exactly as it did, and you can now select, copy and search it.

Our OCR reads English only, so pages in other languages come out with wrong or missing letters. For English, a sharp, straight, high-contrast scan gives far better results than a skewed phone photo. Expect to proofread numbers and names either way.

The file blocks copying

PDFs can carry two kinds of password. One stops the file opening at all. The other, a permissions password, lets anyone open it but tells viewers to block copying, printing or editing. That's the one behind a greyed-out Copy command.

If it's your own document, or the owner has given you the right to reuse the text, run it through Unlock PDF. Since the file opened without a prompt, leave the password field blank; a file with only permission restrictions unlocks that way, and you'll get back a copy with the protection removed. If the tool asks for a password anyway, ask whoever sent the file for an unrestricted version. Restrictions on licensed reports or exam papers are usually there on purpose.

The paste comes out as gibberish

Inside a PDF, text is stored as codes that point at shapes in an embedded font. To turn those codes back into letters, a viewer needs a lookup table in the file. Some software leaves that table out or uses a custom encoding, so the page displays perfectly while copying hands you the raw codes. Switching viewers rarely helps, because the information simply isn't in the file.

OCR is the way around it, since it reads the shapes rather than the codes. There's a catch, though. Our OCR skips pages that already have text so it doesn't duplicate anything, and a gibberish page counts as having text. You need to turn the pages into pure images first:

  1. Convert the PDF to PNG at 300 DPI.
  2. Put those PNGs back into a PDF with PNG to PDF, adding them in page order.
  3. Run the new file through OCR PDF.

The result is a scan-style PDF with a proper text layer. It's larger than the original and the text is no longer vector, so keep the original for reading and use the OCR copy for copying.

The text is right but the line breaks aren't

A PDF doesn't know about paragraphs. It stores lines placed at positions on the page, so when you copy, each line ends with a break, and a word hyphenated across two lines stays hyphenated. Copying a dozen pages this way means a lot of fiddly selecting.

PDF to Text pulls every page's text into one .txt file, with a blank line between pages. The line breaks are still there, but you only have to clean them up once. In Word, open Replace, tick Use wildcards, and replace ([a-z,])^13 with \1 followed by a space. That rejoins any line ending in a lowercase letter or comma, which leaves most real paragraph endings alone because they end in a full stop.

Common questions

Why can't search find words I can see on the page?

Same causes as copying. On a scan there's no text to search, and on a file with a broken font the search is looking for letters that are stored as other codes. After OCR, search works normally.

Is it OK to remove copy restrictions?

On your own files, yes. On someone else's, only if they've given you permission, which is usually easiest to get as an unrestricted copy from them. Our Unlock tool doesn't guess or crack passwords. It works with the one you already have.

Related free tools