Skip to content

PDF-SDK 2.4.1 is out.See what’s new

PDF-SDK
Search

Find text anywhere in a PDF

Your users search the document and step through the matches. Your code gets every match with its page and position.

Try it in the live demo

PDF text search, for users and for code.

  • Search in the editor

    Type a word and step to the previous or next match.

  • Search from code

    Get every match with its page and the rectangles it covers.

  • Case-sensitive or not

    Match exactly, or ignore case.

  • Read text in order

    Read a page’s text blocks in reading order for your own indexing.

From your code.

Lists every match with its page and position.

See the API reference
const doc = await PDFDocumentEditor.open(bytes);

for (const match of doc.search('invoice')) {
  console.log(match.page, match.rects);   // where it is on the page
}

Search questions.

Yes. Search returns every match with its page and the rectangles it covers, case-sensitive or not.

Yes. A free 7-day trial unlocks every feature on every platform, in any app, with no watermark and no card — and the live demo runs the web editor in your browser.

Try it in your app.

A free trial unlocks every feature on every platform, in any app. Open a document today.

Talk to us

Questions about licensing, several apps, volume, or OEM and site terms — we will work out what fits.