Skip to content

Scan a document from a photo

Photograph a letter, a receipt or an ID card on any table, even at an angle. The page’s corners are found for you, the photo is pulled flat into a straight rectangle, and shadows are lifted so the paper turns white. Save every page in one PDF.

or drop them anywhere
No upload · runs 100% in your browser
A photo of an open art book lying at an angle on a wooden desk, and the scan made from it: the pages straightened and flattened into a clean rectangle.

From a crooked photo to a clean page

  1. 1

    Photograph the page

    Lay it on a surface darker than the paper and take the photo from above. An angle is fine; the whole sheet with a little table around it works best. Pick several photos at once for a multi-page document.

  2. 2

    Check the corners

    The straight edges of the sheet are found in the photo and the outline is drawn over it; if they cannot be found, the page tells you. If a corner is off, drag its handle. On a phone, a magnifier above your finger shows exactly where the corner sits.

  3. 3

    Choose a look

    Clean evens out the light and makes the paper white while keeping coloured ink, stamps and signatures. Black & white gives crisp text and the smallest PDF. A page lying on its side is turned upright; Left and Right turn it a quarter turn if needed.

  4. 4

    Add pages and save

    Add more photos or take them one by one, put the pages in order, then save one PDF with each page at its real size or every page on A4 or Letter, or a JPG or PNG per page.

Which look to choose

The four looks, what they suit, and the size of one A4 page in the PDF (average of six letters photographed with a 12-megapixel camera)
LookBest forWhat happensOne page in the PDF
CleanLetters, forms with coloured stamps, signed contractsShadows and the yellow or blue tint of the room’s light are divided out; paper becomes white, ink keeps its colourabout 370 KB
GrayscalePrinted pages, newspaper cuttings, pencil notesThe same cleaning, then shades of grayabout 360 KB
Black & whiteText-only pages, receipts, anything you will fax or archiveEach pixel becomes black or white against the brightness around it, so faint print survives a shadowabout 25 KB
OriginalPhotos, drawings, pages where colour matters exactlyOnly the flattening; colours and light stay as photographedabout 540 KB

Black and white pages are stored in the PDF with CCITT Group 4 compression, the coding office scanners and fax machines use. The other looks are stored as JPEG at quality 90. A 12-megapixel phone photo of an A4 sheet gives a page of about 1600 × 2260 pixels, roughly 190 dpi, which prints and reads well; grayscale saves little over Clean because the colour of a white page costs JPEG almost nothing.

How the page is found and flattened

A copy of your photo, 512 pixels across and made by averaging every pixel of the original, so a 12 or 50 megapixel phone photo gives the same answer as a small one, is searched for straight edges with a colour edge detector and a Hough transform, the classic way to find lines in an image. Pairs of roughly opposite lines are combined into four-sided outlines, and each outline is scored by how much of its sides follow real edges, whether those edges stop at its corners (a side that runs on is usually the edge of a second sheet or of the desk), whether the colour changes from table to paper all the way round, and whether the band just inside it has the even colour of a paper margin. The best outline is then refined on a sharper copy to a fraction of a pixel. A wooden table’s grain and seams, a woven mat or the printed boxes of a form can also make long straight lines, so a second test looks for the sheet itself: the largest bright, nearly colourless area, its holes (the print) filled in. When that area is a clean four-sided shape it confirms the outline, or replaces one that took a table seam instead of the paper’s edge. When nothing scores well enough, the page says so instead of guessing, and Try again looks once more at two other sizes.

A page lying on its side is turned upright: rows of text leave whole empty rows between the lines, so the direction of the lines shows which way the page runs, and the edge of the page that is higher in the photo becomes its top. Without text, only a clearly tall sheet lying across is turned.

Flattening uses the four corners to work out the camera’s angle (a homography) and redraws the page as a rectangle. The page’s true width-to-height ratio is recovered from the perspective itself, so an A4 sheet photographed at a steep angle still comes out A4-shaped, and a receipt stays long and thin.

We tested it on 120 phone-sized photos (12 megapixels) made for this page: letters, receipts and ID cards tilted up to 25 degrees on wood, dark, cloth, grey, tiled and white surfaces, with uneven light and soft shadows. The corners landed within 1% of the page’s diagonal in 91 of them, and in 67 of the 80 taken on wood, dark, cloth and grey surfaces. We also check eleven harder desk photos: two sheets overlapping, a page with a curled edge, a page shot at a steep angle, white paper on a white desk, a shadow across the page, a page running out of the frame, an open book and a photo with no page at all. In all eleven the right sheet is found (within 3% of the diagonal), or the page says that there is none. And because real phone photos are bigger and messier, we check 14 more made like them: a white sheet on wooden tables with strong grain and plank seams, on a woven mat, with a form full of printed boxes, curled edges, a reflection of the ceiling light or a thumb on a corner, at 12 and 50 megapixels and turned by the camera’s orientation tag. The sheet is found in all of them. The misses were white pages on white desks, floor-tile grout that looks like a page edge, and cards whose dark header band blends into the table; there you drag the corners. Finding the page takes about 0.3 seconds on a laptop, in a background thread, so the page never freezes.

Tips for a sharp phone scan

  • Contrast under the page: a wooden table, a dark folder or a coloured bed sheet makes the edges easy to find. White paper on a white desk is the hard case.
  • Light from the side, not from your phone: stand so your shadow does not fall on the page, and turn the flash off. Clean removes soft shadows, but a hard-edged one can leave a faint line.
  • Fill the frame, keep a margin: get close enough that the page covers most of the photo, with a strip of table visible on every side.
  • Hold still and tap to focus: flattening cannot sharpen blurred letters. Use the main camera rather than the ultra-wide lens, which bends straight edges near the sides.
  • Glossy paper: tilt the page or the phone slightly until the glare spot moves off the text.
  • ID cards and receipts: choose the matching shape so the card prints at 85.6 × 54 mm and the receipt keeps its 80 mm width.

What it does not do

  • Text recognition: pages are pictures. Run the saved PDF through Make PDF Searchable to search and copy its text, or use Image to Text for a single page.
  • Curved or folded paper: the flattening assumes a flat sheet. Book pages that bend into the spine stay bent.
  • Several documents in one photo: one page per photo. Photograph two receipts separately.
  • Very large photos: photos are worked on at up to 24 megapixels (16 on iPhones, iPads and phones with 4 GB of memory or less) and pages are saved at up to 9 megapixels, about 300 dpi for an A4 sheet (6 megapixels on those phones).

Your paperwork stays on your phone

Scanner apps and upload sites often keep copies of payslips, passports and medical letters on their servers. This page does every step, from finding the corners to writing the PDF, inside your browser tab. Close the tab and nothing remains.

Questions & answers

Are my documents uploaded anywhere?

No. The photo is decoded, flattened and cleaned by this page inside your browser tab, and the PDF is assembled there too. Bank statements, IDs and contracts never leave your phone or computer, and there is no account.

Why were the corners not found?

The corner finder looks for the straight edges where the paper meets the table and for the bright, plain area of the sheet itself. White paper on a white or light grey desk, a page that fills the whole photo, or a hand covering a corner can hide them. When that happens the page says so and places the four handles inside the photo. Tap Try again for a second look at other sizes, or drag the handles onto the corners; on a phone a magnifier shows the corner under your finger. Next time, put the page on a darker surface.

Can I search or copy the text in the PDF?

Not straight away: each page is saved as a picture of the page, like a scanner makes. Open the saved PDF in Make PDF Searchable on this site to add an invisible text layer, or use Image to Text to copy the words out of a page.

What size are the PDF pages?

By default each page gets its real size: A4 and US Letter pages print at their real size, an ID or bank card is 85.6 by 54 mm, and a receipt is 80 mm wide and as long as it needs to be. With the Auto shape the size is worked out from the page’s shape: an A4-shaped page becomes A4, a long strip an 80 mm receipt, anything else its own pixels at 200 dpi, never larger than A4. Choose All pages A4 or All pages US Letter to put every page on the same sheet; a page of another shape keeps its size, centred.

Can it straighten a page from a book?

Only if the page lies flat. The flattening corrects the angle of the camera, which turns a flat sheet into a rectangle, but it cannot unbend paper that curves into the spine or is folded. Press the book open under glass, or photograph one page at a time from straight above.

Learn more