How to Split a PDF and Auto-Rename Files by Page Content
Question details
The user needs to split a multi-page PDF document into individual files and automatically rename each new file using specific text, such as a person's name, found on the corresponding page.

- Product
- PDF Editor
- Device & OS
- not provided
- Scenario
- Splitting a master PDF (e.g., HR documents or invoices) into individual pages and naming each resulting file based on the unique person's name or data listed on that specific page before importing them into a software system.
- Observed behavior
- Default PDF split features usually generate files with sequential numbers rather than dynamically extracting on-page text for filenames, which requires manual renaming or custom scripts.
Ensure that the text you want to use for the file names is selectable and machine-readable (not a flattened image) so that bookmarks or scripts can accurately extract it.
Use Top-Level Bookmarks to Split and Auto-Rename
By creating a bookmark for each page using the desired text, you can split the PDF based on those bookmarks. The resulting files will automatically adopt the bookmark names.
This method bridges the gap between manual renaming and full programming. It allows you to dictate exactly what each file will be named by setting up the document structure beforehand.
Open your PDF document and expand the Bookmarks navigation panel on the side of the screen.
Go to the first page, highlight the text you want to use as the filename (e.g., the employee's name), and click 'Add Bookmark'. The selected text will automatically become the bookmark's name.
Scroll through the document and repeat this process to create a top-level bookmark for every page or section you wish to separate.
Navigate to your PDF editor's 'Split Document' tool. Choose the option to 'Split by top-level bookmarks' and run the process. The exported files will be named according to your bookmarks.

Automate Renaming with Custom JavaScript
For massive documents where manual bookmarking is impractical, you can use Acrobat JavaScript or external automation tools to extract on-page data and split the file.
Split and Organize PDFs with WPS Office
WPS Office provides a highly intuitive PDF editor that makes splitting, managing, and organizing your PDF pages simple. You can easily navigate documents, extract specific pages, and organize your files efficiently.
- 1. Open Your PDF: Launch WPS Office and open the multi-page PDF file you need to organize.
- 2. Access Split Tool: Navigate to the 'Page' tab on the top ribbon and click on the 'Split PDF' tool.
- 3. Set Split Rules: Choose how you want to split the document, such as separating it into individual single pages or specific page ranges.
- 4. Export Files: Select your output directory and click 'Split' to generate your new, separated PDF files instantly.

Frequently Asked Questions
Can I automatically split a PDF by an invoice number or name?
Most standard PDF editors cannot do this automatically out-of-the-box. To split and name a file by on-page content like an invoice number, you typically need to use a custom automation script (like Acrobat JavaScript) or manually create bookmarks for each section and split by those bookmarks.
Why are my split PDF files just numbered sequentially?
By default, PDF split tools append a sequential number (e.g., File_1, File_2) to the original filename to guarantee that each new file has a unique name, which prevents files from overwriting each other during the split process.
How do I split a PDF by bookmarks?
In supported PDF editors, you first create top-level bookmarks for the pages you want to separate. Then, open the 'Split Document' tool and choose 'Top-level bookmarks' as your splitting method. The resulting files will use your bookmark names as their filenames.




