Google Drive logo
AI logo
Google Sheets logo

Workflow template

Extract PDF text from Google Drive into Google Sheets

Extract text from new PDFs in Google Drive and log it in Google Sheets. Read embedded text, use OCR when needed, and save file details, page count, a review flag and extracted text.

How it works

From a new Drive PDF to an extraction-results row

1 Trigger · 1 Filter · 4 Actions
Google Drive1 · Trigger

New PDF in Google Drive

Poll for newly created files directly inside your chosen Drive folder. Replace the folder placeholder before activating and upload a new PDF for testing.

FastHook2 · Filter

Only application/pdf

Continue only when the source MIME type exactly matches application/pdf. Other file types stop before download and extraction.

Google Drive3 · Action

Download File

Download the detected PDF by its Drive ID. The following extraction step consumes this File output, not the trigger’s metadata sample.

AI4 · Action

Extract PDF

Use Auto mode to read embedded text and apply GPT-6.1 Sol OCR on pages with little or damaged text. Return extracted text, page count and a review flag; select FastHook credits or your own OpenAI account for OCR.

Google Sheets5 · Action

Create Spreadsheet Once

Create PDF extraction results with a Results worksheet and six prepared headers on first use. Reuse that spreadsheet for later executions of this workflow.

Google Sheets6 · Action

Append PDF Results — RAW

Append the file ID, file name, Drive web link, page count, review flag and extracted text into A–F. RAW input keeps extracted text from being interpreted as spreadsheet formulas.

The result

One six-column row for each extracted PDF

The first use creates the spreadsheet; later PDFs append to the same Results worksheet. Review the extracted text before using it, especially when the review flag is set.

Prepared Results headers in the exact A–F order.
file_idfile_namedrive_linkpage_countneeds_reviewfull_extracted_text
fictional_pdf_exampleExample plan.pdfhttps://drive.google.com/file/d/fictional_pdf_example/view1falseExample plan Review the draft on Friday.

Illustrative extraction, not a live OCR result. The sample text, page count and review flag show the output shape; a false flag is not a guarantee of perfect transcription.

Before activation

Set up your workflow

  1. Connect Drive and choose the PDF folder

    Select a source folder the Drive connection can read and replace the placeholder. Only direct children are monitored. Use a new PDF of at most 4 MiB and 10 pages.

  2. Configure extraction and Sheets

    Choose FastHook credits or your own OpenAI account for OCR, then connect Google Sheets. Keep Auto for embedded text with OCR fallback; choose OCR mode for mixed pages or drawings with an unreliable text layer. Review the prepared spreadsheet title and headers.

  3. Test with an actual downloadable PDF

    Choose a PDF sample in the trigger, then test Download File and the following steps in order. Creating the spreadsheet during testing creates a real file. Inspect its row and extracted text, then activate for newly uploaded PDFs.

Details and limitations
  • PDF and spreadsheet limits apply. Use PDFs up to 4 MiB and 10 pages. Google Sheets cells are limited to 50,000 characters; the entire extraction is mapped into one cell. Review long documents before relying on this row format.

  • OCR is conditional in Auto mode. Native embedded-text extraction makes no model call. OCR uses FastHook credits or your own provider account according to the selected Account. Auto applies OCR to pages with little or damaged text; use OCR mode for unreliable mixed pages or drawings.

  • Extraction needs human review. Unclear source text may remain incomplete or incorrect. Inspect the review flag and the text against the original PDF. The workflow logs extraction results; it does not summarize or validate their factual content.

  • The created spreadsheet is reused. The creation step keeps its first spreadsheet for this workflow, including one created by a test. To create a different file after first use, add a new creation step. Appends do not update old rows, and reruns can append the same PDF again.

Questions about this template

Does every PDF use paid OCR?

No. Native embedded-text extraction makes no model call. Auto uses OCR where pages have little or damaged text; OCR uses the FastHook credits or own provider account selected in the extraction step.

What PDF and cell limits should I plan for?

Each PDF can be at most 4 MiB and 10 pages. The full extracted text goes into one Sheets cell, whose limit is 50,000 characters. Non-PDF MIME types are filtered out.

Why can’t I test extraction with only the fictional trigger metadata?

Extraction needs the File produced by Download File. Select an actual PDF sample the Drive connection can download, then test Download File and the remaining steps in order.

Will each PDF create a separate spreadsheet?

No. Create Spreadsheet Once creates the file on first use and reuses it for this workflow. Testing can create that first file. Later PDFs append rows; use a new creation step if you need a different spreadsheet after first use.

Explore connected apps