◆ Acrobat · organize

Crop pages using an automated script or API

I’ve scanned three invoice pages, the purchase order, and the delivery note. Put them in order: [document=PO], invoice…

3ready prompts
1real task

When to use it

real situations

AI prompts

3 ways to ask · copy any one
AExecute — “help me do it”Show me code to crop all pages in a PDF using...…+
Show me code to crop all pages in a PDF using the Adobe PDF Services API with [language] and [crop settings].
when the reply comes backWant to batch crop multiple PDFs at once?
BImprove — “do it better”How can I make my PDF cropping script faster or...…+
How can I make my PDF cropping script faster or more reliable when using the Adobe PDF Services API?
when the reply comes backNeed help setting up authentication for the API?
CDecide — “help me choose”Should I use Adobe PDF Services API or another tool...…+
Should I use the Adobe PDF Services API or another tool to crop PDF pages in my project? Explain the pros and cons.
when the reply comes backCurious how to preview cropped results before saving?

How to do it

the tool · the steps · what to avoid
  1. 1

    Open the PDF file you want to crop in Adobe Acrobat Pro.

  2. 2

    Press Ctrl+J (Windows) or Cmd+J (Mac) to open the JavaScript console.

  3. 3

    Paste a JavaScript snippet that sets the crop box for the desired pages, such as: this.setPageBoxes('Crop', 0, this.numPages-1, [left, bottom, right, top]); replacing left, bottom, right, top with your crop coordinates in points.

    Best practiceYou can use the Action Wizard to automate running JavaScript on multiple files for batch cropping.

  4. 4

    Press Enter to execute the script and crop the pages.

  5. 5

    Save the PDF to apply the changes.

    CautionCropping with JavaScript only hides content outside the crop box; it does not delete it from the file.

You can use the JavaScript console or create an Action Wizard sequence to crop pages programmatically in Acrobat Pro.

This runs in the Acrobat app - there is no separate API for this task.

Glossary

words on this page
APIA way for different software to talk to each other automatically.ExampleAn online store uses an API to automatically send shipping details to a delivery service.
CropTo cut off the unwanted outer parts of an image.ExampleI will crop the photo to remove the distracting background elements.
AuthenticationHow you prove who you are when using an online service.ExampleEntering your password and a code from your phone provides authentication to access your bank account.

The real tasks

the one, listed here
Need to bundle mixed scans for vendor approval on tight deadline

FAQ

about this task

You send a request to the API with your PDF file and the crop settings you want. The API processes your file and returns a new PDF with the pages cropped as you specified.

Cropping cuts away parts of the page you don't want, while resizing changes the whole page's size. Cropping keeps the content the same size but shows less of it.

Yes, you can set the API to crop just specific pages by giving it the page numbers or a range, instead of cropping the whole document.

Using an API lets you crop many files automatically, saves time, and avoids mistakes that can happen when doing it by hand.

You need to set up credentials like an API key or OAuth token to prove your app is allowed to use the Adobe service. This keeps your files and account secure.

Sources

where this comes from
Copyright © LLOS.ai · 2026 — original pedagogy, voice, and design — all rights reserved.
Built on public evidence: O*NET®, ESCO, Wikipedia, U.S. Bureau of Labor Statistics, forum demand signals.