Skip to content
EditFlip
ENRO
Back to blog
Devices

How to search for a word in a PDF on a Mac

Find any word or phrase in a PDF with Preview, Safari or Spotlight, and fix the scanned PDF where search finds nothing.

Eric Rada · Founder · · 7 min read

In short

  • Open the PDF in Preview, press Command-F, type the word and press Return. Preview lists every page where it appears.
  • If nothing is found in a PDF where you can see the word, the PDF is a scan: pictures of pages, with no text to search.
  • Make a scanned PDF searchable with OCR

Searching a PDF on a Mac takes one shortcut. Command-F works in Preview, where PDFs open when you double-click them, and it works in Safari when the PDF is open in a browser tab. You type a word, the Mac highlights it on the page, and you jump from one match to the next. For a two-hundred-page manual or a long contract, it is the difference between a minute and an afternoon.

There is one case where it fails, and it confuses a lot of people. A PDF that was scanned or photographed holds pictures of pages, not letters, so there is nothing for search to find. That kind of file has to be run through OCR, which reads the pictures and adds real text to the PDF. This guide covers the normal search first, then Spotlight for finding the right file, then the fix for scans.

On EditFlip, step by step

  1. Step 1

    Check that the PDF really is a scan

    Open the PDF in Preview and search for a word you can see on the page. If Preview highlights it, the file already has text and you do not need these steps. If it finds nothing in a PDF that came from a scanner or a phone camera, go on.

  2. Step 2

    Choose the PDF on EditFlip

    In Safari or any other browser on your Mac, open editflip.com. Press Choose files and pick the scanned PDF, or drag it from a Finder window onto the page. The Options panel comes up with the file and its tiles. Nothing is uploaded, the reading is done on your Mac.

  3. Step 3

    Press OCR

    Among the tiles you will see OCR. It is offered only for a scan with no text of its own, so if the tile is not there, the PDF is already searchable. Press it and wait while the pages are read one by one. A long scan takes a few minutes. It reads English and Romanian.

  4. Step 4

    Download and search in Preview

    Press Download and open the new PDF in Preview. It looks the same as before, because the pages are still the scanned pictures, but now Command-F finds words in it and you can select and copy text. Search for a word from the middle of the document as a test.

Searching in Preview

Preview is the app that opens PDFs on a Mac unless you have chosen another one. Its search field sits in the toolbar at the top of the window. Apple notes that you may need to make the window wider to see it. Command-F puts the cursor in that field without reaching for the mouse.

Type a word or a phrase. Preview shows the results in the sidebar and highlights the matches on the pages. Use the Next and Previous buttons to move between them, or click a result in the sidebar to jump straight to that page.

When you are done, clear the search field to get the normal view back. The highlights are only on your screen. Nothing is saved into the PDF.

Getting better results in Preview

When you type more than one word, Preview looks for that exact phrase. “payment terms” finds only the places where the two words stand together. To find pages that have any one of the words, Apple’s guide says to click the magnifying glass in the search field and choose Any Match.

The list of results can be sorted in two ways. Search Rank puts the pages with the most matches first, which is useful when you are looking for the chapter that is really about your word. Page Order lists them from the start of the document to the end, better when you want to read every mention in turn.

Search does not care about capital letters, so “invoice” also finds “Invoice”. It does care about spelling. If you are not sure how a name is written, search for the part you are sure of.

Searching a PDF in Safari

A PDF that you opened from a web page is shown inside Safari, and you do not have to download it to search it. Apple’s instructions are the same as for any web page: press Command-F, type what you are looking for, and Safari highlights the matches. Press Return to go to the next one.

Other browsers on a Mac work the same way, with the same shortcut. The search in a browser is simpler than Preview’s, though. You get the matches one after another and a count, but no list of pages to sort.

For a long document that you will come back to, download the PDF and open it in Preview. You get the sidebar with all the results, and the file is still there when the web page is gone.

Finding which PDF has the word: Spotlight

Sometimes the problem is not where the word is in the PDF, but which PDF it is in. Spotlight, the search of the Mac itself, looks inside documents as well as at their names. Press Command-Space, type a word that you remember from the document, and PDFs that contain it can turn up in the results.

For a more careful search, open a Finder window and press Command-F there. That starts a Spotlight search in the window, and you can narrow it to one folder and to PDF files only.

The same limit applies as in Preview. Spotlight can find a PDF by the words in it only when those words are real text. A folder of scanned invoices can be found by file name, but not by what is written on the pages, until the scans are made searchable.

Why search finds nothing in a scanned PDF

A PDF can hold two very different things that look the same on the screen. A PDF saved from Word, from a web page or from an accounting program holds letters. A PDF from a scanner, or made from photos of paper, holds one picture for each page. To your eyes both are a page of text. To the Mac the second one is a photograph, and a photograph has no words in it.

The test takes a few seconds. Try to select a single word by dragging across it. In a text PDF, the word is highlighted. In a scan you usually cannot pick out a word in the same way, and Command-F comes back with nothing.

On recent versions of macOS you may notice that you can still copy words from a scanned page, because the Mac recognises text in pictures while you look at them. That helps for one line. It does not put the text into the file, so search across the whole document still does not work.

What OCR does, and how good it is

OCR stands for optical character recognition. A program looks at the picture of each page, works out which shapes are letters, and writes that text into the PDF, invisibly, exactly behind the place where each word is seen. The page looks the same as before. The difference is that search, selecting and copying now work.

How well it reads depends on the scan. Clean, straight, printed pages come out almost without mistakes. Small print, faded copies, pages photographed at an angle, stamps over the text and handwriting give errors, and a word that was read wrongly will not be found when you search for it. If a search misses something you know is there, try a shorter piece of the word.

OCR on EditFlip reads English and Romanian. It makes the scan searchable, but it does not turn it into a document you can retype. If you need to change the words, convert the result to Word after OCR and work on that.

Other reasons a search comes back empty

Not every failed search means a scan. A word that is split by a hyphen at the end of a line is stored in two pieces, so search for the first half. Some PDFs made by design programs store headings as drawings and not as letters, so a title may not be found even though the body text is.

Accents and special letters can also get in the way. If a document was typed without them, or with them, type the word the same way. Numbers are another trap: 1,250.00 and 1250 are different strings to a search, so try just the first digits.

And sometimes the word is simply not there. Before you decide that the search is broken, look for a common word like “the” or “and”. If that is found, search works, and what you were looking for is written differently or sits in another file.

Choose a scanned PDF, press OCR and download a copy that Preview, Safari and Spotlight can search. It reads English and Romanian. Free, no account, and the document stays on your Mac.

Make a scan searchable on EditFlip →

Questions

How do I search for a word in a PDF on a Mac?

Open the PDF in Preview, press Command-F, type the word and press Return. The matches are highlighted and listed in the sidebar.

What is the shortcut to search a PDF on a Mac?

Command-F. It works in Preview and in Safari, and in other browsers too.

Why can’t I search my PDF in Preview?

Most likely it is a scanned PDF, which holds pictures of pages and no text. Run it through OCR and search will work on the new copy.

How do I search for an exact phrase in Preview?

Just type the phrase. Preview looks for the words together. To match any of the words, click the magnifying glass in the search field and choose Any Match.

Can Spotlight search inside PDFs?

Yes, when the PDF has real text. Press Command-Space and type a word from the document. Scanned PDFs can be found only by their file name until they are made searchable.

How do I make a scanned PDF searchable on a Mac?

Choose it on EditFlip, press OCR in the Options panel and download the result. The new PDF looks the same and can be searched in Preview.

Does OCR change how my PDF looks?

No. The pages stay the same scanned pictures. The text is added invisibly behind them so that search, select and copy work.

Is my document uploaded for OCR?

No. On EditFlip the pages are read in your browser, on your own Mac. The file is not sent to a server.

Do it right in your browser.
Free, no account. Your files stay on your device.
Make a PDF searchable