How to Deskew PDF: Straighten Crooked Scanned Pages

Fix crooked, tilted, and skewed scans in your PDF files with these free methods.

By PeacefulPDF Team

What Is PDF Deskewing?

Deskewing is the process of automatically detecting and correcting the tilt or rotation in scanned document pages. When you scan a physical document, the paper rarely feeds through the scanner perfectly aligned. Even a few degrees of rotation can make text harder to read, confuse OCR software, and make your documents look unprofessional.

A deskew operation analyzes the orientation of text lines and images on each page, calculates the angle of rotation, and then rotates the page back to its proper alignment. Most deskewing tools can correct rotations of up to 15 degrees automatically.

Why Deskewing Matters

Crooked scans cause more problems than you might think. OCR accuracy drops significantly when text is tilted even a few degrees. Search engines and document management systems may fail to index skewed content properly. And if you are sharing scanned documents with colleagues or clients, crooked pages look sloppy.

Common scenarios where deskewing helps include scanning multi-page contracts, digitizing old paper records, processing faxed documents, and preparing documents for archiving.

Free Online Tools to Deskew PDF

iLovePDF

iLovePDF offers a dedicated deskew tool among its PDF suite. Upload your PDF, and the tool automatically detects and corrects skewed pages. It processes each page individually, which means even if only some pages are crooked, it handles them correctly. The free tier supports files up to 15 MB.

PDF24 Tools

PDF24 provides a free online deskew tool with no watermarks. Upload your file, and it scans each page for skew angles and corrects them. PDF24 also has a desktop version if you prefer not to upload sensitive documents to the cloud.

Sejda PDF

Sejda includes automatic deskewing as part of its PDF optimization features. Free users can process documents up to 200 pages or 50 MB. It runs entirely in the browser for smaller files, which means your documents never leave your machine.

Deskewing with Desktop Software

Adobe Acrobat Pro

Acrobat Pro includes a built-in deskew feature in its Scan optimization tools. Go to Tools > Enhance Scans, then select Enhance > Clean Up. Acrobat analyzes each page, detects skew, and corrects it. You can apply this to individual pages or the entire document at once.

ScanTailor Advanced

ScanTailor Advanced is a free, open-source tool specifically designed for post-processing scanned documents. It offers fine-grained control over deskewing, along with other cleanup tasks like splitting pages, removing borders, and adjusting margins. It is available for Windows, macOS, and Linux.

ABBYY FineReader

ABBYY FineReader applies automatic deskewing as part of its OCR preprocessing pipeline. If you need both deskewing and text recognition, FineReader handles both in a single pass, saving time on multi-page documents.

Command-Line Deskewing

ImageMagick

If you are comfortable with the terminal, ImageMagick provides powerful deskewing capabilities. First, convert your PDF pages to images, then apply the deskew operation:

convert input.pdf -deskew 40% output.pdf

The percentage value controls how aggressively the algorithm searches for skew. A value of 40% works well for most documents. You can also process individual pages extracted as TIFF or PNG files for more control.

ocrmypdf

The ocrmypdf tool includes an automatic deskew option that runs during OCR processing. Use the --deskew flag:

ocrmypdf --deskew input.pdf output.pdf

This is one of the most efficient approaches because it deskews and adds a searchable text layer in a single step. It is free, open-source, and available on all platforms via Python pip.

Tips for Better Scan Results

Prevention beats correction. Use a document feeder that aligns pages properly. Clean your scanner glass regularly to avoid artifacts. Scan at 300 DPI or higher for best deskew accuracy. And if you are scanning bound books, use a V-shaped book scanner cradle to minimize curvature near the spine.

Most modern scanner drivers include an automatic deskew option during scanning. Check your scanner software settings and enable it if available. This corrects skew at the source and produces cleaner results than post-processing.

Which Method Should You Use?

For quick one-off corrections, an online tool like iLovePDF or PDF24 gets the job done in seconds. For bulk processing scanned archives, ocrmypdf with the --deskew flag is hard to beat. And if you need visual control over the correction process, ScanTailor Advanced gives you the most flexibility.