# Reorder pages in a PDF

Create a new PDF with every source page exactly once in a supplied one-based sequence, and keep the selected source file unchanged.

Organize PDF pages

[Reorder pages in the browser](/browser/reorder-pages/) [Read the .NET guide](/docs/pdf/operations/)

Reorder summary

**Input**

PDF and page sequence

**Output**

Reordered PDF

**Package**

[OfficeIMO.Pdf on NuGet](https://www.nuget.org/packages/OfficeIMO.Pdf)

**Runs on**

Browser-local WebAssembly or .NET

**Microsoft Office**

Not required

**License**

MIT

The one-based sequence must include every source page exactly once; subsets, omissions, and duplicates are rejected.

[Browse all PDF workflows](/pdf/)

Practical steps

## Create a PDF with a new page order

Describe one complete permutation of the source pages and write the resolved order into a separate document.

1. **Select**Choose one PDF and review the current page order.
2. **Sequence**Enter every source page exactly once in the desired order, such as 3,1,2,4-last.
3. **Create**Generate the reordered PDF and download its operation report.

Reordering writes pages in the sequence supplied by the caller. That sequence must be a full permutation: every source page appears exactly once, with no omissions or duplicates. It is useful for corrected scan order, assembled packets, covers placed after generation, and workflows that need a deterministic page tree before signing.

## Reorder from .NET

```csharp
using OfficeIMO.Pdf;

PdfDocument source = PdfDocument.Load("scan.pdf");
PdfPageSelector order = PdfPageSelector.Parse("3,1,2,4-last");
PdfDocument reordered = source.Pages.Reorder(order);

File.WriteAllBytes("scan.reordered.pdf", reordered.ToBytes());
```

The operation creates a new document and preserves the page count. Use [extract pages](/pdf/extract-pages/) or [delete pages](/pdf/delete-pages/) when the output should contain only a subset.

## Separate order from rotation

Reordering changes where pages appear; it does not change their orientation. Apply [rotate pages](/pdf/rotate-pages/) separately so each operation and report says exactly what changed.

## API used on this page

- [`PdfDocument`](/api/pdf/officeimo-pdf-pdfdocument/)

<!-- PowerForge markdown artifact sha256:14AD6AC789229F96316D35FEF13F5748012AA75E1830EA5C76CD2B36FDC8ABFA -->
