ForHosting KIT · Documents & PDF

PDF duplex print page order

Five pages printed long-edge fill three sheets, pages 1 and 2 on the first, with every side upright and a blank back on the last sheet. Enter the page count and flip mode to get the full sheet map before loading the tray. Free in your browser.

  • Free
  • Runs in your browser
  • No sign-up
  • Your data stays on your device
Use it from WebAPIEmailTelegramApp soon
If you enter
Page count
5
Duplex mode
long_edge
You get
Sheet count
3

Duplex printing puts two PDF pages on one physical sheet, but the flip axis changes how the back side is oriented when you re-read the stack. Long-edge flip is the usual book binding for portrait documents: you turn the sheet left-to-right and the back stays upright. Short-edge flip is the calendar or notepad style: you flip top-to-bottom and the back content appears rotated one hundred eighty degrees relative to the front. Print shops, office runners, and automation scripts need a deterministic sheet map before they load a tray or configure a driver, not a guess after a ruined ream. This PDF duplex print page order checker accepts a positive page count and a duplex mode, returns every page’s sheet number, side, and orientation, lists each physical sheet with front and optional back, and flags when the last sheet has a blank back because the page count is odd.

What long-edge and short-edge duplex mean for page order

A duplex job always pairs pages onto sheets in reading order: sheet one carries page one on the front and page two on the back when two pages exist; sheet two carries pages three and four; and so on until every page is assigned. The sheet count is the ceiling of the page count divided by two. The duplex mode does not change which logical page number sits on which sheet side; it changes how the back is oriented for binding and for manual refeed.

Drivers and finishers that offer flip on long edge versus flip on short edge implement this same physical idea. Knowing the map in advance prevents the classic failure where odds print fine and evens come out inverted or in the wrong reading order after the stack is turned. Use the pages array for per-page tooling and the sheets array when you care about physical stock, tray capacity, or blank backs.

Driver and UI previews

Show users which page lands on which side—and whether backs rotate under short-edge flip—when they toggle long-edge versus short-edge duplex.

CI for print pipelines

Assert stable sheet-side mappings in automated tests whenever duplex presets or page counts change in a document workflow.

What is the difference between long-edge and short-edge?

Both modes pair pages the same way (1–2 on sheet 1, 3–4 on sheet 2, …).

What happens if the page count is zero?

A zero-page document has no sheet mapping; provide a positive page count. Failed validation is not billed.

Does the flip mode change which page goes on which side?

No. Pages always pair in reading order, page 1 on the front of sheet one and page 2 on its back, and so on. The flip mode only changes how the back side is oriented.

What happens with an odd number of pages?

The last sheet gets a printed front and a blank back, and the result flags it rather than inventing an extra page. Five pages, for example, need three sheets, the third with nothing on its back.

Why do my even pages come out upside down?

Because the flip axis does not match how the stack is turned. With short-edge flip each back is rotated 180 degrees relative to the front; the sheet map shows that orientation before you print, not after a ruined ream.

Everything on this page is available programmatically. This section is for teams who want to wire it into their own systems; everyone else can just use the tool above.

POSThttps://api.kit.forhosting.com/pdf/duplex-page-order-check

Prefer to automate it? One authenticated POST creates the task; the result comes back by webhook or a signed link. The same capability also runs here on the web, by email and from Telegram — and soon from our app too.

curl -X POST https://api.kit.forhosting.com/pdf/duplex-page-order-check \
  -H "Authorization: Bearer $KIT_KEY" \
  -H "Content-Type: application/json" \
  -d '{"page_count":5,"duplex_mode":"long_edge"}'
{
  "page_count": 5,
  "duplex_mode": "long_edge"
}
{
  "task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
  "type": "pdf.duplex_page_order_check",
  "status": "queued",
  "_links": {
    "result": "/tasks/tsk_…/result"
  }
}

The API is asynchronous: the call returns a task_id immediately and the result arrives by webhook. Polling is capped at 1 req/s per task.

Per request$0.002

Published price — no tokens, no invented credits. A failed task is never charged.

max_mb25
max_pages200
HTTPCodeMeaning
401unauthorizedMissing or invalid API key.
402insufficient_balanceYour balance doesn't cover the task price.
404unknown_typeThat task type doesn't exist.
429rate_limitedToo many requests. Use the webhook instead of polling.

A zero page count is rejected with invalid_input.

What long-edge and short-edge duplex mean for page order

When the page count is odd, the final sheet has a printed front and a blank back—the checker reports that with blank_back_last set true and omits a back_page on the last sheet object rather than inventing a phantom page. Long-edge mode (also accepted as book-style aliases) marks every side upright: flip the sheet on its long edge and the back reads correctly without rotating the paper one hundred eighty degrees. Short-edge mode (calendar-style aliases) marks each back side as rotated_180: flip on the short edge and the back content is upside-down relative to the front if you hold the stack without that flip.

Input contract, response shape, and error behaviour

Negative counts are also rejected. POST a JSON body with two required fields. page_count is a non-negative integer (aliases pages, n, count); it must be a whole number because you cannot print a fractional page. duplex_mode is a string normalized to long_edge or short_edge (aliases mode, flip, binding). Accepted long-edge spellings include long_edge, long-edge, longedge, flip_long, long, and book; short-edge spellings include short_edge, short-edge, shortedge, flip_short, short, and calendar. Missing fields, non-finite numbers, non-integers, and unknown mode strings fail with invalid_input and are not billed. A page_count of zero is explicitly rejected with a clear message that a positive page count is required—empty documents have no sheet map. On success the body echoes page_count and the normalized duplex_mode, reports sheet_count and blank_back_last, lists pages as objects with page, sheet, side (front or back), and orientation (upright or rotated_180), lists sheets with sheet and front_page plus optional back_page and back_orientation when a back exists, and includes a short human summary string for logs and UI. Example: five pages in long_edge mode yield three sheets, pages one through five mapped front-back-front-back-front, blank_back_last true, and every orientation upright. The same five pages in short_edge mode keep the same sheet pairing but mark pages two and four as rotated_180. Pair the response with your own N-up or booklet layout tools if you need imposition beyond simple duplex pairing; this endpoint only answers sheet-side order for standard duplex.

Where a duplex page-order API earns its keep

Accessibility and finishing teams that flip finished stacks for binding checks can show which pages will appear inverted under short-edge mode before anyone loads the tray. Print rooms and managed print services use a duplex page-order checker before releasing multi-hundred-page jobs so operators can confirm stock counts (sheet_count) and whether the last sheet needs a blank back insert. Office automation that prints invoices or packets double-sided can assert blank_back_last and orientation in tests instead of relying on a physical sample every time a driver preset changes. PDF pipeline authors who expose long-edge versus short-edge toggles in a UI can preview the sheet map in the browser for free, then call the same contract from a worker at $0.002 per successful request when a job is queued.

Pre-press sheet planning

Convert a PDF page count and chosen flip mode into sheet_count, front/back pairs, and blank-back flags before loading stock or configuring the driver.

How do I check PDF duplex print page order?

Send page_count (positive integer) and duplex_mode (long_edge or short_edge). The API returns each page’s sheet, side, and orientation plus a per-sheet front/back map.

What if my PDF has an odd number of pages?

sheet_count is still ceil(page_count/2). The last sheet has a front page only; blank_back_last is true and back_page is omitted on that sheet.

What does the duplex page-order checker cost?

The browser tool is free. API requests use prepaid KIT balance at $0.002 per successful call; invalid input is not billed.

Read the full KIT documentation →