PDF Tools

All tools, free, in your browser.

VoxScan› PDF Tools› View & Edit› Remove Shadow from Scanned PDF

Remove Shadows from a Scanned PDF

Flatten the hand shadow, book-spine gradient or side lighting on a scanned or photographed page. The tool estimates the paper shade region by region and divides it out, so the background turns uniformly white while the text keeps its contrast. Live preview, nothing uploaded.

Background normalisationAdjustable strengthClean white paperLive preview
All Tools › ›

How to remove a shadow from a scanned PDF

Upload the PDF and the preview shows the first page with its lighting flattened. Instead of one brightness value for the whole page, the tool divides the page into a grid, works out what the paper looks like inside every cell — the brightest shade that is not ink — and smooths those estimates into a map of the lighting. Every pixel is then divided by the lighting under it: a paper pixel under a shadow and a paper pixel in full light both come out white, while ink keeps its distance from the paper around it. The Strength slider sets how fine that grid is; the Clean paper option snaps anything that is nearly white to pure white so the background is uniform. Adjust while watching the preview, click Process, and every page is corrected the same way in your browser, with nothing uploaded.

Step by step

  1. Drop the PDF onto the upload area.
  2. Start with Strength at 50. A single broad shadow across the page (a hand, a phone, a window) usually needs less; a book-spine gradient plus patchy lighting needs more.
  3. Check the preview for two failure signs: if a large dark graphic has faded, lower the strength; if there are still gray patches, raise it.
  4. Keep Clean paper to pure white on for documents, off for pages with light photographs or pastel backgrounds you want to keep.
  5. Click Process and download.

Where scan shadows come from

The most common shadow is the photographer's own: a phone held over a page blocks the ceiling light, so the top of the page is bright and the bottom sits in the shadow of the phone and the hand holding it. Bound books produce a different pattern — the page curves down into the spine, and the last few centimetres get progressively darker in a smooth gradient. A flatbed scanner with the lid open records a small document with a dark halo around it, and a desk lamp to one side lights the page unevenly from left to right. All of these have one thing in common: the paper is not one shade but a slowly varying field of shades, and that is exactly what a global brightness or contrast change cannot correct, because any value that whitens the dark side will blow out the bright side.

How background normalisation works

The technique is the one used inside document cameras and OCR pre-processing pipelines, sometimes called flat-field correction or background subtraction. The page is split into cells — between 12 and 60 across the shorter side, depending on the strength setting. In each cell the tool takes the 85th-percentile value of every colour channel: bright enough to skip the ink, which rarely covers more than a fifth of a cell, but robust against the odd specular highlight. Cells that come out much darker than the page's overall paper shade — less than about 45% of it — cannot be shadow, because no ordinary shadow darkens paper that far; they are treated as content (a photograph, a filled table header, a logo) and their lighting value is borrowed from the surrounding cells instead, which is what keeps dark graphics from being bleached. The grid is blurred so cell borders do not show, then interpolated back up to full resolution to give a smooth estimate of the lighting at every pixel. Dividing the original by that estimate, with the gain capped at three times so noise in very dark corners is not amplified into garbage, produces a page whose paper is flat white and whose ink keeps its original contrast relative to the paper. A second, finer pass then cleans the residue that a single pass leaves along the soft edge of a shadow, and the optional clean-up step sets any pixel whose three channels are all above 232 to pure white.

Choosing the strength

Strength controls the size of the cells, and therefore the size of the features the tool treats as "lighting" rather than "content". At low strength the cells are large, so only shadows that span a good part of the page are removed and mid-tone graphics are left alone. At high strength the cells are small, so patchy lighting, creases and even the ring left by a coffee cup are flattened — but a light-gray graphic or a pale screenshot larger than a cell can be read as shaded paper and lightened. Solidly dark graphics are protected at any strength by the content rule described above. For a typed page with a hand shadow, 30–50 is the usual range; for a photographed book page, 50–70; for forms with large light-gray fills, stay below 40 and accept a little residual shading.

Shadows, darkness and tilt are three different problems

If the whole page is uniformly gray rather than shaded on one side, the cheaper fix is a single white point — the dark scan tool does that and is gentler on photographs. If the paper is white but the text is faint, raise contrast with the adjust contrast tool. If the page is crooked, correct it with the deskew tool — do that before shadow removal, because rotating afterwards leaves white wedges at the corners that would confuse a second pass. Once the page is flat and straight, OCR recognises the text far more reliably than on the shaded original.

Avoiding the shadow next time

Stand so the light comes from the side rather than from behind you, hold the phone parallel to the page, and move your body out of the light path. A document-scanning app helps more than any editing step: the VoxScan scanner app for iOS and Android locates the page edges, evens out the lighting and straightens the perspective at capture time, so the exported PDF starts out clean. For books, pressing the spine flat and scanning one page at a time avoids the gradient altogether.

Frequently asked questions

Will it remove a shadow that covers half the page?

Yes — that is the easy case. The grid estimates the paper shade under the shadow and outside it separately, so both regions come out white.

Does it work on colour documents?

Yes. Each colour channel is normalised on its own, so a coloured shadow (warm lamp light on one side) is corrected along with the brightness, and coloured text and logos keep their hue.

My photograph faded after processing. Why?

Solidly dark images are protected, but a light or mid-tone photograph larger than one grid cell can be read as shaded paper and lightened. Lower the strength so the cells become larger than the photo, turn off Clean paper, or leave that page out and process it separately.

Why is the correction capped at three times?

In very dark corners the paper value can be close to black; dividing by it would multiply sensor noise and JPEG artefacts into visible garbage. The cap keeps those corners a little darker but clean.

Is the output searchable?

The pages are rebuilt as images, so add a text layer afterwards with the OCR tool — it works better on the flattened page than on the shaded original.

Is anything uploaded?

No. The PDF is rendered, corrected and rebuilt in your browser; it never leaves your device.