Apply the Same Bates Number to Every Page of Each PDF in Acrobat
Question details
Assign one Bates identifier to each PDF and apply it to every page in that file.

- Product
- Adobe Acrobat Pro
- Device & OS
- not provided
- Scenario
- Process approximately 100 PDFs, optionally adding page numbers and filenames containing the document identifier and page range.
- Observed behavior
- Every page in a PDF should show the same document identifier, while different files receive different identifiers.
Prepare a list of unique identifiers and decide where the identifier and optional page numbers should appear. Test the Action on a few sample PDFs first, because batch processing order may be difficult to control and the script below prompts for each identifier.
Use an Acrobat Action to apply one identifier per PDF
Use this approach to process multiple PDFs while entering a unique document identifier for each file.
The script adds the identifier as a text watermark, not as a native Acrobat Bates-numbering record. It prompts once per PDF, so it does not depend on the files being processed in a particular order.
This example does not automatically assign identifiers, add page numbers, or rename files. Those tasks require additional steps or a more advanced custom workflow.
In Acrobat Pro, open All tools > Use guided actions or Action Wizard, then choose New Action. Add Execute JavaScript to the Action.
Open the Execute JavaScript settings and enter: var id = app.response({cQuestion: 'Enter the document identifier for this PDF:', cTitle: 'Document identifier'}); if (!id || !id.replace(/\s/g, '')) { throw new Error('A document identifier is required.'); } this.addWatermarkFromText({cText: id, nStart: 0, nEnd: this.numPages - 1});
Add a Save step to the Action, choose an output folder, and save the Action. Run it on the PDFs and enter the identifier that belongs to each file when prompted.
Open sample output PDFs to check the watermark's position and appearance on every page. If needed, use Acrobat's Edit a PDF > Header & Footer tools to add page numbers, and save or rename files to include their identifier and page range.

Apply a document identifier to PDF pages in WPS Office
For a manual workflow, use a text watermark in WPS PDF to place the same identifier across a file's pages. Repeat for each PDF and save the output with a descriptive filename.
- 1. Open the PDF: Open WPS Office, select PDF, and open the file you want to label.
- 2. Add the identifier: In the PDF editing tools, choose Watermark > Add Watermark, select a text watermark, and enter the document identifier.
- 3. Apply it to the file: Set the page range to all pages, adjust the watermark's position and appearance, and apply it.
- 4. Save and repeat: Use Save As to name the output file with its identifier and page range, then repeat the process for the other PDFs.

Frequently Asked Questions
Does the Acrobat script create native Bates numbering?
No. The example uses addWatermarkFromText to place an identifier on each page. It does not create a native Acrobat Bates-numbering record.
Can I add page numbers as well as the document identifier?
Yes. In Acrobat, open Edit a PDF > Header & Footer and add page numbers separately. Check the output to make sure they do not overlap the identifier.
Will the Action assign the identifiers in filename order?
The example does not assign identifiers automatically; it prompts you for one per PDF. Acrobat Action processing order can be difficult to control, so match each prompt to the file being processed.
Can the script automatically include the page range in each filename?
Not as written. Use Save As or rename the output files after processing, or develop and test a custom workflow that handles output names and file permissions.




