On-device AI — professional-grade, fully private.

Images

How to Fix Perspective in a Photo (Documents, Whiteboards and Leaning Buildings)

Fix perspective in a photo: flatten an angled document or whiteboard, straighten leaning buildings, keep the true proportions and export a clean rectangle.

Updated November 25, 20267 min read

To fix perspective in a photo, open the perspective correction tool, add the picture, press Find the edges so the four handles jump to the page or the board, nudge any corner that landed short and press Correct perspective. The result is a flat, rectangular image, as if the camera had been square to the subject. This guide explains what perspective distortion is, when correcting it helps, and how to get a sharp, correctly proportioned result from a document, a whiteboard, a painting or a tall building.

What perspective distortion is

A camera sees the world from one point, so anything closer to it looks bigger. Photograph a sheet of paper from straight above and its four corners are the same distance from the lens, so it stays a rectangle. Tilt the phone and the near edge is now closer than the far edge, so it comes out longer. The rectangle becomes a trapezium, and the text shrinks towards the far side.

Buildings suffer the same thing sideways. Point the camera up at a tower and the top is further from the lens than the bottom, so the walls lean in as they rise. Photographers call this converging verticals, and the shape it makes is a keystone: wide at the bottom, narrow at the top, like the wedge-shaped stone in an arch. Correcting it means telling the software which shape should really be a rectangle, or which lines should really be upright, and letting it map every pixel back.

When to correct perspective, and when to leave it

SubjectCorrect it?Why
Contract, receipt, form or book pageYesA flat page prints properly and is far easier for text recognition to read
Whiteboard or projected slideYesNotes taken from the side of the room come back square and legible
Painting, poster or printYesA reproduction should show the artwork's real proportions
Building facade or tall interiorUsuallyUpright walls look natural, but a partial correction often reads better than a full one
People, faces, landscapesNoThere is no rectangle to restore, and a stretched face looks wrong long before a wall does

If the picture is only tilted, with a sloping horizon but no converging lines, you need rotation instead. Straighten Image does that, and the guide to straightening a crooked photo explains the difference.

Fixing perspective, step by step

1

Add your photo

Open Perspective Correction and drop in a JPG, PNG, WebP, GIF, AVIF or BMP. The photo appears under Mark the corners, with the Corrected preview beside it.

2

Pick a preset and a method

Under Preset, choose Document, Whiteboard, Building or Artwork as a starting point. Keep the Correction method on Four corners for anything with visible corners, or switch to Guide lines for architecture.

3

Find the edges, then refine

Press Find the edges and the tool shows how confident it is. Drag any handle that landed on a shadow onto the true corner: a magnifier follows your finger, and the arrow keys move a handle one pixel at a time.

4

Choose the output shape

Leave Output shape on Measured from the photo to recover the real proportions, or force A4 portrait, Letter portrait, Square or a Custom ratio.

5

Correct and download

Press Correct perspective, pick PNG, JPEG or WebP under Output and press Download.

Automatic edge finding, four corner handles, guide lines for buildings and a measured output shape. Free: one image up to 25 MB, exported up to 4,096 px on the longest side. Pro: up to 100 images in one ZIP. Runs on your device, not our servers.

Fix perspective in a photo

Scanning documents and whiteboards with your phone

A phone photo of a page is a good scan once the angle is removed, and a few habits make it better. Put the page on a surface that contrasts with it, such as a dark desk for white paper, so Find the edges can lock on. Shoot as close to straight above as you comfortably can: the less correction is needed, the less the far edge is stretched. Keep your own shadow off the sheet and let the page fill most of the frame.

For a whiteboard, stand as central as the room allows and keep all four corners in the shot. If a corner is hidden, place its handle where the two edges would meet. Once the board is square, Image to Text reads it far more reliably than the angled original; the guide to extracting text from an image covers that step.

Measured from the photo matters most here. Four corners carry enough information to work out the camera's angle, and from that the page's true width-to-height ratio, so an A4 sheet comes out A4-shaped without you saying so. If the result looks slightly too tall or too wide, the page was probably curled or a corner is off; A4 portrait or Letter portrait forces the known shape.

Leaning buildings and converging verticals

A building rarely gives you four clean corners, but it always gives you verticals: door frames, window columns, drainpipes. Switch to Guide lines and press Vertical. The tool finds the strongest near-upright edges and makes them parallel. Level does the same for horizontal lines, and Both corrects the two axes at once. You can also drag across the photo to add your own guide, and Clear guide lines starts again.

Correcting the whole frame leaves empty wedges at the corners. Trim to a clean rectangle cuts the largest rectangle that fits inside the result. To keep every pixel instead, leave the trim off and, under Show fine adjustment, set Outside the photo to Solid colour.

A fully corrected tower can look top-heavy, because our eyes expect a little convergence when we look up. In the fine adjustment panel, ease Vertical keystone back slightly; a hint of lean often looks more natural. Horizontal keystone, Rotate, Stretch and Scale are there for the final touches.

Keeping the result sharp

A correction moves every pixel, and a steep one stretches the far side much more than the near side. Detail that was never recorded cannot be invented, so the far edge of a sharply angled page is always the softest part. Start from the full-resolution original rather than a copy sent through a chat app, shoot closer to square, and keep Resampling on Lanczos, the filter that holds fine detail best; Bicubic is a close, slightly softer second.

PNG keeps text edges crisp and is the safe choice for documents headed for text recognition. JPEG and WebP make smaller files for buildings and art. To keep only part of the result, finish with Crop Image; the guide to cropping to an aspect ratio lists the common frame sizes.

Free and Pro

Every correction method, the edge finder, the measured shape, the fine adjustments and all four resampling filters are free. Free corrects one image at a time, up to 25 MB, exported up to 4,096 px on the longest side. Pro removes the size cap, lets you set the export quality and queues up to 100 images in one ZIP; Find the edges in every image looks for the corners again in each photo. Either way, the photo is processed on your device and never uploaded.

Frequently asked questions

How do I fix the perspective of a photo for free?

Open Perspective Correction, add the photo, press Find the edges, drag any corner that is off onto the real corner, then press Correct perspective and download. Free covers one image up to 25 MB.

How do I fix a leaning building in a photo?

Switch the correction method to Guide lines and press Vertical. The tool finds upright edges such as door frames and makes them parallel. Turn on Trim to a clean rectangle to remove the empty corners.

What is the difference between perspective correction and keystone correction?

Keystone correction is one case of it: a subject wider at one end because the camera was tilted. Four-point perspective correction covers that and any other converging-line distortion, on one axis or both.

Will my corrected document have the right proportions?

Usually. Measured from the photo works out the page's real ratio from its four corners. If the page was curled or a corner is off, choose A4 portrait or Letter portrait to force the known size.

Why is one side of my corrected photo blurry?

The side furthest from the camera had the fewest pixels, and correcting it stretches them. Use the full-resolution original, shoot closer to straight on and keep Resampling on Lanczos.

Is my photo uploaded when I correct it?

No. Edge finding, correction and export all happen on your device, so it is safe for contracts, receipts and other private documents.

Keep reading

More in Images →