To extract text from a PDF on Windows, first check whether you can select the text. If you can, copy it in a PDF viewer or convert the whole file with MD Factory. If you can't, the pages are pictures, and the text has to be recognized with OCR.
The two kinds of PDF need different methods. The steps below start with the test that tells you which one you have.
Check whether you can select the text
Open the PDF in Microsoft Edge, Chrome or Adobe Acrobat Reader. Press Ctrl+F and search for a word you can see on the page.
- The word is found and highlighted: the PDF has selectable text.
- Nothing is found, or dragging the mouse across a line does not select it: the page is a picture of text.
One PDF can contain both. A typed report may end with scanned appendices, so run the search on a page from the middle and on one from the end.
Copy text in a PDF viewer
For a few paragraphs, this is the fastest way. Drag the mouse across the text and press Ctrl+C. To copy the whole document, press Ctrl+A, then Ctrl+C. Paste the text into Notepad or Word with Ctrl+V.
Copied text often has a line break at the end of every line, a table arrives as loose lines, and on a page with two columns the text of one column can run into the other. Page numbers and running headers are copied too.
Open the PDF in Word
Word can open a PDF as an editable document. Go to File, then Open, choose the PDF, and select OK when Word offers to convert it. Microsoft says this works best with PDFs that are mostly text, and that lines and pages may break in different places than in the original. The steps are in Edit a PDF.
Use this when you want to keep editing the text in Word. For plain text, or for many files, convert them instead.
Convert the whole PDF with MD Factory
- Open MD Factory and click Add files, or drag the PDF onto the window. To convert every PDF in a folder, including its subfolders, click Add folder.
- Conversion starts right away. When it finishes, the row shows Completed, Needs review or Failed.
- Double-click the result path in the row to open the text.
The text is saved in a file with the PDF's name and the extension .md, in the same folder. Pictures from the PDF go into a folder beside it. The conversion runs on your PC.
Reports/
annual-report.pdf
annual-report.md
annual-report_images/
The .md file is plain text, so Notepad opens it. Headings begin with # and tables are drawn with | characters. The guide to converting PDF to Markdown explains these files in more detail.
Extract text from a scanned PDF
Add a scanned PDF the same way. MD Factory finds the pages that are pictures and recognizes their text with OCR on your PC. In a PDF that mixes typed and scanned pages, the typed text is kept as it is, and OCR runs only on the scanned pages.
OCR can misread faded, crooked or handwritten text. If a row shows Needs review or Failed, click the status, choose the document's language in the OCR language list, and click Retry. The guide to scanned PDFs covers the language setting and what each message means.
For a single scanned page on Windows 11, Snipping Tool can also do it. Press Windows+Shift+S, select the area, then choose Text actions and Copy all text. Microsoft says the text recognition runs on your device: see Use Snipping Tool to capture screenshots.
Check the extracted text
Whatever method you use, compare the result with the PDF before you rely on it:
- Read across a column break and a page break to check the order of the sentences.
- Delete page numbers and running headers that interrupt a sentence.
- Compare every figure you will use, such as amounts, dates and ID numbers, with the PDF.
- In a table, check that each value sits in the right row.
Text from a scan needs the closest look: a misread digit looks as plausible as a correct one.
Which method to use
| Method | Best for | Limits |
|---|---|---|
| Copy in a viewer | A few paragraphs from a PDF with selectable text | Does not read scans. Line breaks and tables need cleanup. |
| Open in Word | A text PDF you want to edit as a Word document | The layout can change. Works best with mostly text. |
| MD Factory | Whole PDFs, folders of PDFs and scans | The result needs a check against the PDF. |
| Snipping Tool | One scanned page, or part of it, on Windows 11 | One area of the screen at a time. |
Questions
Can I extract text from a password-protected PDF?
MD Factory does not convert password-protected PDFs. Open the PDF with its password in your viewer, save a copy without the password if you are allowed to, and convert the copy.
How do I extract text from many PDFs at once?
Click Add folder in MD Factory. Each PDF gets its own text file. To search across all of them, see how to search inside many PDF and Word files.
Does MD Factory keep the layout of the PDF?
No. You get the text with its headings, lists and tables, not the look of the page. Keep the PDF for anything that depends on the layout.