Files are processed in your browser, not uploaded. Privacy →
Skip to guide

Extract text

Why does extracted PDF text show garbled characters?

By DeckleUpdated

Extracted PDF text shows garbled characters when the PDF's fonts do not record which letter each shape stands for, or when the file is opened with the wrong encoding. The page looks fine because the shapes are drawn correctly, but the stored characters are wrong, so PDF to text, copy and paste and search all get the same nonsense. Check the encoding first; if the text is still wrong, the fix is OCR on those pages or a fresh export from the source document.

PDF to text

Pages become plain text

Selected PDF pages

Order chosen in the review

UTF-8 text

Words without page formatting

Page boundary: U+000C or a blank line

Conceptual illustration · page separators retain boundaries, not columns, fonts or table geometry.

How to work out what is wrong

  1. Open PDF to text, choose the PDF and use Choose pages to extract just one page with the problem.
  2. Choose Extract text and open the TXT file in a plain text editor.
  3. If the editor offers an encoding option, make sure it is set to UTF-8. Deckle always saves text as UTF-8.
  4. In the PDF, select the same garbled word in a viewer and paste it into the editor.
  5. Compare the two. If the pasted word is garbled too, the problem is inside the PDF. If only the TXT file is wrong, the editor or the next program is misreading the encoding.
  6. Check one more page that came from a different part of the document, because only some fonts may be affected.

What the symptoms tell you

What you see Likely cause What to do
é instead of é, ’ instead of ' The file was opened as Windows-1252 or Latin-1, not UTF-8 Reopen as UTF-8, or set the import encoding
Random letters such as Ifmmp for Hello Font maps shapes to the wrong codes OCR the page, or re-export from the source
Empty boxes or question marks The editor's font lacks those characters Try another editor or font
fi or fl missing from words Ligatures stored without a text mapping Search and replace, or re-export
Strings of symbols only on headings A decorative font with no mapping Retype the headings

The first row is not a PDF problem at all. It happens when a spreadsheet or an older editor assumes a legacy encoding. If the program has an import option, use it and choose UTF-8 as the encoding instead of opening the file directly.

Why a PDF can look right and extract wrong

A PDF font is a set of shapes plus, ideally, a table that says which character each shape represents. Software that embeds only part of a font, or uses a custom encoding, sometimes leaves that table out or fills it wrongly. Printing and viewing still work, because they only need the shapes. Anything that needs the actual letters (search, copy, screen readers and text export) gets whatever codes the font stored.

It turns up most often in PDFs from older publishing software, some report generators and documents that went through several conversions.

PDF to text cannot repair a missing mapping. It exports what the PDF stores. The Verified: line confirms the characters in the file match the PDF's text layer, which is the right check, but it cannot tell whether that layer was correct in the first place.

Fixes that work

  • Fix the encoding when the problem is the é pattern. Reopen the file as UTF-8 or change the import setting in the receiving program.
  • Re-export from the source. If you have the Word, Google Docs or design file, make a new PDF with fully embedded fonts, then extract again.
  • Use OCR on the affected pages. OCR ignores the broken text layer and reads the shapes. Expect to proofread names and numbers. Native PDF text vs OCR text explains the trade-off.
  • Retype short passages. For a heading or a single paragraph, typing it is faster than any workaround.

Tips

  • Test a single page first. A one-page extract shows whether the whole file is affected or only certain fonts.
  • Search the PDF for a garbled word. If the viewer cannot find a word you can see on the page, its mapping is wrong.
  • Keep the original PDF. It remains the correct visual record even when its text is unusable.
  • Watch numbers. Some fonts map digits correctly and letters wrongly, or the other way round, so check both.

Frequently asked questions

Why does copied text from my PDF come out as random symbols?

The PDF's font does not map its shapes to the right letters. Any tool reading the text gets the same symbols. OCR or a new export from the source fixes it.

Is the TXT file from Deckle UTF-8?

Yes. Every file from PDF to text is UTF-8. If accented letters look broken, the program opening it is using a different encoding.

Can Deckle fix garbled characters?

No. PDF to text exports the characters the PDF stores and does not correct them. A broken mapping needs OCR or a fresh export.

Why are some words missing "fi" or "fl"?

Those pairs are often drawn as a single ligature shape. If the font does not map it back to two letters, extraction drops it or writes one odd character.

  • PDF to text to test one page and see what the text layer holds
  • Split PDF to separate the affected pages for OCR
  • PDF to PNG to save a sharp image of a page you need to retype

Sources