InterLAB tools · Camera · edges · PDF

Document scanner

Shoot a page with your phone camera or upload a photo — the tool finds the edges, corrects the perspective, removes shadows and combines pages into one PDF. Photos are processed on your device only.

Free, no sign-up

PDF · A4 · Letter

Photos are processed on this device only and live in this tab's memory — they are gone after a reload; only the settings are saved in the browser. Photo metadata (EXIF, location) is removed during processing.

Add pages

Shoot the document with the camera or upload photos — the page edges are found automatically, the page is straightened, the text is sharpened and pages are combined into one PDF.

Drop photos here or paste from the clipboard (Ctrl+V)

How the tool works

  1. Capture

    The rear camera at high resolution: the page outline is highlighted live on the video; the shutter is a button, Space or Enter; auto-capture can fire when the outline holds still for one second. Or upload photos — several files, drag and drop or paste.

  2. Page edges

    Corners are found automatically; move them with a mouse or finger (with a 3× magnifier under the finger) or with the arrow keys. “Find edges” repeats the search, “Whole image” resets the frame.

  3. Straightening

    The page quadrilateral is mapped to a rectangle: the size comes from the edge lengths or the A4/Letter proportion, with 90° rotation either way. The result updates while you drag the corners.

  4. Filters

    Original, “Colour+”, greyscale and B&W with a before/after slider. Shadows and uneven light are removed by estimating the paper background.

  5. Pages and PDF

    Up to 40 pages: reorder by dragging or with buttons, duplicate, retake, delete. The PDF is written by our own writer right in the browser — A4, Letter or fit to image, with margins and JPEG quality; the size estimate is shown in advance. Each page can be downloaded as JPEG or PNG.

Algorithms and standards

  • Page detection: greyscale (Rec. 601) → 5×5 Gaussian blur → Sobel operator with non-maximum suppression (the Canny step) → a Hough transform where each edge pixel votes only for angles near its gradient direction → pairs of opposite sides → the convex quadrilateral with the longest confirmed edges.
  • Perspective: a homography from 4 point pairs (an 8×8 system, Gaussian elimination); every output pixel maps to a point on the photo with bilinear interpolation.
  • Shadows: the paper background is estimated per block (maximum after blur, dilation, smoothing) and the image is divided by it — the paper becomes evenly white.
  • B&W: Sauvola adaptive threshold T = m·(1 + k·(s/128 − 1)) over a local window; mean and variance via integral images.
  • PDF: ISO 32000-1 (PDF 1.4 compatible), JPEG embedded without re-encoding (DCTDecode filter), a cross-reference table with exact offsets.

Original

What it does
Straightening only, colours as captured.

Colour+

What it does
The paper background is levelled (shadows removed), text darker, stamps and signatures keep their colour.

Greyscale

What it does
Same shadow removal, no colour — a smaller file.

B&W

What it does
Sauvola adaptive threshold: clean white background and black text, the smallest file.
Filters

A4 (ISO 216)

Size
210 × 297 mm
PDF page
595.28 × 841.89 pt
Long / short
1.4143

Letter (ANSI A)

Size
8.5 × 11 in (215.9 × 279.4 mm)
PDF page
612 × 792 pt
Long / short
1.2941
Paper sizes and proportions

150

A4
1754 px
Letter
1650 px

200

A4
2339 px
Letter
2200 px

300

A4
3508 px
Letter
3300 px
Output resolution (long side of the page)

Browser support

  • The camera needs HTTPS and getUserMedia: Chrome, Edge, Firefox, Safari (iOS 14.3+). The torch works only where the camera reports it (usually Chrome on Android).
  • Processing runs in a background thread (Web Worker) so the page stays responsive; if it is unavailable, the same code runs on the main thread.
  • Photo upload: JPEG, PNG, WebP. Save iPhone HEIC photos as JPEG first (or switch the camera to “Most Compatible”).

Limitations

  • No text recognition (OCR): the PDF consists of images, its text cannot be selected or searched.
  • Edges are found when the page stands out from the background and all four sides are visible; a white sheet on a white desk, folded corners or fingers on the edges — adjust the corners by hand.
  • Curved pages (an open book) are straightened as flat — the curve remains.
  • “From the edges” proportions come from the side lengths in the photo; under strong perspective choose A4 or Letter for exact proportions.
  • Photos are scaled to 4096 px on the long side; at most 40 pages per document.

Privacy

  • Photos and PDFs are made on your device and are not sent to a server; camera frames never leave the browser. Only a short summary — the page count, PDF format and filter — may go with a request.
  • Photo metadata (EXIF, location, phone model) is removed: every image is re-encoded through a canvas.
  • Only the settings (filter, paper, PDF, quality, auto-capture) are kept in localStorage; photos live in this tab's memory only.
  • The camera starts only on your click and stops with “Done”, when the tab is hidden and when you leave the page.
  • Analytics receives only the fact of an export, its format and a page-count range — no content.
  • The result reaches us only if you send a request yourself and keep the “Attach the result” box ticked — the form shows exactly what will be sent. Files and images are never sent with a request.

Related tools

All tools · 40
Tell us about your task — we'll review your request and get back to you

Want paperless document workflows?

InterLAB builds business software: document capture from the camera, archives, search and integrations with accounting systems. The first conversation about your task is free.

  • The first short conversation is free — we choose the format
  • NDA — yours or ours
  • Pricing after a brief and an agreed scope

Please do not send passwords, access keys or source code through this form — we will agree a safe way to share access separately.

By clicking the button you agree to the processing of your personal data.