Logo
POST /api/pdf/page/rotate

Rotate PDF Pages API

Send a PDF URL and the turns you need, get back the same PDF with every page the right way up. Made for sideways scans, phone uploads and landscape tables.

  • Free plan
  • No credit card

Request

curl -X POST https://apdf.io/api/pdf/page/rotate \
  -H "Authorization: Bearer TOKEN" \
  -d file="FILE_URL" \
  -d rotations[0][angle]="-90" \
  -d rotations[0][pages]="1-3" \
  -d rotations[1][angle]="+180" \
  -d rotations[1][pages]="z"

Every page
the right way up.

Each rotation pairs an angle with a set of pages. Send several to fix a whole scan in one call.

delivery-notes.pdf example
-90
-90
-90
—
+180
POST /api/pdf/page/rotate
p.1
p.2
p.3
p.4
p.5
The rotations parameter
+90
A quarter turn clockwise
-90
A quarter turn counterclockwise
+180
Half a turn, for pages upside down
90
No sign: set the page to 90°, whatever it was
(no pages)
The angle applies to every page

No more tilted heads.

Sideways pages slow every reader down. Fix them once, in your pipeline, before anyone opens the file.

Scanner output

Pages fed into the scanner the wrong way come out sideways or upside down. Turn them upright before archiving.

Phone uploads

Documents photographed on a phone often end up sideways in the PDF. Fix the orientation before the review starts.

Wide tables

Landscape tables in a portrait report are hard to read on screen. Turn just those pages so they read naturally.

Field paperwork

Signed delivery notes come back scanned in every direction. Turn them upright before they reach your records.

Rotate from anywhere.

Turn pages right where your files already arrive. One account and one monthly allowance behind every route.

Your code

One authenticated POST from any language. Copy-paste samples in cURL, Node.js, Python and more.

POST /api/pdf/page/rotate
Open the endpoint docs
Zapier

Pick the action in any Zap and map files from earlier steps. No code and no servers to run.

Rotate PDF Pages
Use it in Zapier
n8n

Add the Apdf node to any workflow, on n8n Cloud or self-hosted, and chain it with your automation.

Rotate PDF pages
Use it in n8n
AI agents

Let Claude, ChatGPT, Gemini or your own agent run it through the MCP server, on any paid plan.

rotate-pdf-pages
See what agents can do

1,000 rotated PDFs
a month. Free.

Start on the free plan and move up only when your volume does — up to 1,000,000 operations a month on Business.

  • One call is one operation, however many pages.
  • Only calls that do the work are counted.
  • Hard limits, so no surprise overage charges.
Plan PDF operations / month
Hobby Free
$0 / month
1,000
Pro
$39–$99 / month
20,000 – 60,000
Business
$149–$899 / month
100,000 – 1,000,000

Rotating pages, answered

No. You decide which pages to turn and by how much, for example from a choice your users make in your app.
No. Pages turn in quarter steps only: 0, 90, 180 or 270 degrees, with a sign to turn relative to the current orientation or without one to set it.
No. Only the rotation setting of each page changes. The content is not re-rendered, so text stays selectable and images keep their quality.
As a URL: Apdf downloads the file, up to 100 MB. In Zapier and n8n you can map the file from an earlier step instead.
The response contains a download URL that stays valid for 60 minutes. Store the file on your side if you need it longer.
After the API call

Your code made the PDF.
Then it went dark.

Opened, read, signed or ignored — you never see any of it. Send the PDFs you generate as personal links, and every open, page read, comment and signature comes back to your software as a webhook. Need it signed? Same link. Same account, same API key, one more call.

Your PDF, after sending Live
document:loaded CFO
page:read p4 · 38s
signature:signed 11:48

API · Webhook · MCP

Fix sideways pages
in one call.