# Delete Pages from PDF

> A free online tool that deletes the pages you list from a PDF and keeps the other pages in their original order, copying them as they are with the qpdf command-line program.

Use this free tool to delete pages from PDF files by typing the page numbers you want gone. It removes the pages you list and keeps the rest in their original order, so you can remove pages from PDF files without installing software. You download a new file, and your original is not changed.

## Key facts

- Input: one PDF up to 10 MB without an account (50 MB signed in), up to 100 pages (500 signed in); the pages to delete are typed as numbers and ranges such as 2,4-6, with z for the last page and r2 for the second from last.
- At least one page must stay; a page number past the last page makes the job fail and the credits are returned. Encrypted PDFs are refused and never opened or broken.
- The kept pages are copied without re-encoding; bookmarks and form fields of the source are not kept. In our test deleting pages 2 and 4-5 of a generated 6 page PDF of 60 KB gave a PDF of 3 pages and 48 KB.
- API: POST the PDF to https://api.aiipworld.com/v1/uploads, then POST https://api.aiipworld.com/v1/pdf-jobs with op pdf_delete, params pages and the upload id, and poll GET /v1/jobs/:id.
- Free without an account: 20 PDF jobs per day per visitor, no watermark. Signed in, each job costs 1 credit plus 1 credit for each started 20 MB of result beyond the first 20 MB (100 free credits every month).
- Files are deleted automatically: 10 minutes after conversion without an account, 1 day with a free account.

## How it works

1. Upload the PDF you want to edit.
2. Type the pages to delete in "Pages to delete", such as 2,4-6.
3. Click "Delete pages".
4. Check the preview and the line "Removed N pages; M of K pages are left".
5. Download the result, named pages-removed.pdf.

## How to delete pages from PDF

To delete pages from a PDF, upload your file, list the pages to remove, and run the job. The result is a new PDF that keeps every page you did not list, in its original order. This pdf page remover works on one PDF at a time, so run the job again if you need to remove more pages from another file.

Results vary with the file. Our measurements were made on generated test files, not real documents. In one test, we removed pages 2 and 4-5 from a generated 6 page text PDF of 60 KB. The result had 3 pages and was 48 KB, and the text showed that pages 1, 3 and 6 were kept.

## Type the pages to delete

The field "Pages to delete" takes page numbers and ranges. Separate items with commas. Page numbers start at 1, and zero is not valid. Use z for the last page and r2 for the second page from the end.

The order you type does not matter, and typing a page twice has no effect. We tested 5,2,2 on a 12 page PDF and got 10 pages left.

- 2,4-6 removes pages 2, 4, 5 and 6.
- z removes the last page.

## Delete a range of pages

To delete a block of pages, or to remove PDF pages in a row, use a dash. The range 3-7 removes pages 3 through 7. You can mix ranges and single pages in one entry, such as 1-3,5.

You cannot type "all odd pages" as a keyword, and the API has no odd or even option either. Write the page numbers you want, up to 200 characters, or run the tool twice with different lists.

## Delete the last pages

Use r-codes to count from the end. The code r1 is the last page, and r2 is the second page from the end. You can combine these with other entries, so r2,4 removes the second-to-last page and page 4.

To remove everything from page 2 to the end, type 2-z. This is a useful way to delete pdf pages at the back of a long document when you know how many pages to keep at the front.

## The other pages are not changed

The pages you keep are copied as they are, with no re-encoding. The text, fonts and images on those pages keep their quality. The pages are copied with qpdf, a command-line PDF program that runs as a separate process.

The original file is not changed. The result is a new file, so you cannot restore a removed page from the result alone. Keep your original copy until you have checked the new PDF.

## What is not kept: bookmarks and form fields

Bookmarks (the outline) and form fields from the source PDF are not kept in the result. The result is built only from the pages you keep, so these items are left out.

If your PDF has bookmarks or form fields, check the result; they are not kept. If you need them in the final file, use your original file and a PDF editor that keeps them.

## Limits: size and pages

The free web tool allows 20 jobs per day per visitor across the PDF tools. Without an account, each uploaded file has its own human check and counts toward 40 uploads per day per visitor.

Without an account, a PDF can be up to 10 MB and 100 pages. Signed-in users can use up to 50 MB and 500 pages. The web tool gives a signed-in job 60 seconds and an anonymous job 30 seconds, and it handles one job at a time.

- Delete pages costs 1 credit, plus 1 credit for each started 20 MB of the result beyond the first 20 MB.
- Failed and timed-out jobs are refunded in full.
- There is no watermark on the result.

## Encrypted and damaged files

Before any work, the file must start like a PDF, with the marker %PDF- within the first 1024 bytes. Encrypted PDFs are refused, whether they are password protected or have permission restrictions of any strength. No password is accepted, and no attempt is made to open or break the protection.

A damaged PDF is repaired automatically when possible, and the result panel says so. If it cannot be repaired, the job is refused. The setting "Repair a slightly damaged PDF automatically" is on by default. With it off, a damaged file is refused.

## Delete pages from PDF in your code

Upload each file with a raw POST to https://api.aiipworld.com/v1/uploads, using Content-Type application/pdf. Each request takes one file, and the answer contains an upload_id. Then POST JSON with op, params and files to https://api.aiipworld.com/v1/pdf-jobs, and poll GET /v1/jobs/:id until the job succeeds, fails or times out.

Send your API key as Authorization: Bearer `<API key>` or as x-api-key. An upload can be used once and expires after 1 hour if unused. The download_url is a short-lived signed link. There is no batch endpoint and no webhooks yet.

Possible errors include 400 invalid_params, 413 file_too_large, 422 not_a_pdf, 404 upload_not_found, 402 insufficient_credits and 429 rate limited. A failed job can return error_code values such as encrypted_pdf, corrupt_pdf, page_out_of_range and no_pages_left. The tool page shows a ready cURL, Node and Python example built from your settings. See /docs/ for the general API.

## Privacy: what happens to your file

Your file is sent to our server, and nothing is processed in the browser. We use the uploaded file only to make the result. The working copy of the upload is deleted as soon as the job ends, whether it succeeds or fails.

In the free web tool, the result is deleted after 10 minutes, and the result panel shows how long it will be kept. No history is kept, and download links are short-lived. You must have the right to use what you upload, as stated in our Acceptable Use Policy. The file type is read from the first bytes of the file; the browser checks it before the upload and the server checks it again.

## Questions

### Can I delete pages from a PDF for free?

Yes. This pdf page remover is free in the web tool, subject to daily limits of 20 jobs per day per visitor, and you do not need to sign up for basic use.

### How do I delete one page from a PDF?

Type the page number in "Pages to delete", such as 4, and click "Delete pages". The result keeps every other page in its original order.

### How do I delete several pages at once?

List them in one field, separated by commas, and use dashes for ranges. For example, 2,4-6 removes pages 2, 4, 5 and 6. You cannot type "odd pages" as a keyword, so list the numbers yourself.

### How do I delete the last page?

Type z in "Pages to delete". To remove the second-to-last page, type r2 instead.

### Can I delete every page?

No. A PDF must keep at least one page. If you try to delete all pages, the job fails with "that would delete all 12 pages; a PDF must keep at least one page", and the credits are returned.

### Does deleting pages reduce the quality?

No. The pages you keep are copied as they are, without re-encoding, so their text, fonts and images keep their quality. Results vary with the file.

### Does the original file change?

No. The original file is not changed. You download a new file named pages-removed.pdf, so keep your original if you may need the removed pages later.

### Can I delete pages from a PDF that has a password?

No. Encrypted PDFs are refused, and no password is accepted. This tool is not for removing passwords.

### Why does the tool say a page is outside the document?

You typed a page number larger than the last page. The message reads "is outside the document, which has N pages". In our test, page 20 in a 12 page PDF gave this error, and the credits were returned.

### Can I delete pages from a PDF in my own code?

Yes. Upload the file to https://api.aiipworld.com/v1/uploads, then send the job to https://api.aiipworld.com/v1/pdf-jobs and poll the job until it finishes. See /docs/ for the general API.

## Related

- [Split PDF Online, Free](https://aiipworld.com/tools/split-pdf/index.md)
- [Merge PDF Files Online for Free](https://aiipworld.com/tools/merge-pdf/index.md)
- [Rotate PDF Online for Free](https://aiipworld.com/tools/rotate-pdf/index.md)
- [PDF to JPG Converter](https://aiipworld.com/tools/pdf-to-jpg/index.md)
- [JPG to PDF](https://aiipworld.com/tools/jpg-to-pdf/index.md)
- [PDF to PNG: Convert PDF Pages to PNG Images](https://aiipworld.com/tools/pdf-to-png/index.md)

Page: https://aiipworld.com/tools/delete-pdf-pages/
