
This flow takes a PDF that has multiple documents in it – for example, multiple invoices in a single PDF – and uses a delimiter word you provide to know where the PDF should be split or processed. It uses AI Builder text recognition (OCR) to read all the text from the PDF to then obtain the page ranges for the different documents in the PDF.
You can customize this flow to use a connector that will do the actual splitting of the PDF like Adobe PDF Services, Encodian, Plumsail among others. Or you can directly specify the page range in supported AI Builder actions like Invoice Processing and Form Processing. To use this flow:
- You will need to have an AI Builder license to use this flow. Don’t have one? You can start a free trial at: https://aka.ms/tryaibuilder?utm_source=powerautomate-cookbook&utm_medium=post&utm_campaign=aib-split-pdf
- Import the attached .zip file in this message into your Power Automate environment.
- After you upload the flow, make sure you go to the ‘Initialize document delimiter variable’ action and define which text delimits the beginning of a new document. For examples, in this PDF example ‘Adatum multiple invoices.pdf’ we use the word ‘Invoice’ as the text that delimits the start of a new invoice.
- When running the flow, the actions ‘Page range for split’ and ‘Last page range for split’ will return the page ranges for each document within the PDF. You can add here any action to split of process the PDF by page range.

Don't hesitate to ask questions in the comments section below! 💬