Demosaicing Trace
A camera sensor records one color per photosite and interpolates the rest. That interpolation leaves a measurable trace. This tool reports one of two things: the trace is there, or it is not measurable on this file — which is the ordinary result for anything that has been resaved or resized.
Drag & drop a file here, Ctrl+V to paste, oror
Runs in your browser
What Is Measured
Every pixel is predicted from the mean of its four orthogonal neighbours. An interpolated pixel sits close to that mean and a recorded one does not, so residual energy differs across the four phases of the 2×2 mosaic. The reported figure is (max − min) ÷ mean over those four phases.
Absence Proves Nothing
The trace is fragile. On a controlled demosaic it measures 2.019; the same image resaved at JPEG quality 75 falls to 0.388, and a single 0.75× resize takes it to 0.015 — level with an image that never had a mosaic. So a file without the trace has told you nothing about how it was made, and this tool never says otherwise.
Web Worker Processing
All analysis runs client-side in a background Web Worker. Your image never leaves your device. It is also analyzed at full resolution and never downscaled first, because resampling would destroy the very signal being read.
How it works
What is a Bayer color filter array?
A Bayer CFA is a mosaic of tiny color filters (RGGB) placed over a camera sensor. Each pixel captures only one color channel, and the camera's image processor interpolates the missing two — a process called demosaicing. Because an interpolated pixel is built from its neighbours, it sits closer to their average than a recorded pixel does, and that difference falls into a repeating 2×2 pattern. That is the trace this tool looks for. For broader metadata analysis, check your photo with the EXIF Checker or examine sensor noise with the Noise Analysis tool.
What this tool actually measures
Each pixel is predicted from the mean of its four orthogonal neighbours and the leftover residual is squared into one of four buckets, according to its position in the 2×2 mosaic. The reported phase spread is (max − min) ÷ mean across those four buckets, and the threshold for calling the trace present is 0.25. Those numbers come from measurement, not from tuning: an image put through a real RGGB mosaic and a bilinear demosaic scores 2.019, while every sample photograph tested scores at or below 0.043. Unlike ELA, which reacts to recompression, this is a question about one specific step in a camera pipeline — and only that step.
Limitations and edge cases
The trace is fragile, and this is the limitation that matters more than any other. Measured on a controlled demosaic: 2.019 untouched, 1.527 after a JPEG q95 resave, 0.542 at q85, 0.388 at q75, and 0.015 after a single 0.75× resize — the last of these is indistinguishable from an image that never had a mosaic at all. Anything that has passed through a website, a messaging app, an export or an editor has almost certainly lost it. That is why this tool has no verdict and no red band: a result of not measurable on this file is the normal case, and it says nothing about whether the image was edited. Flat regions (sky, solid walls) leave nothing to predict from and show gray. Screenshots and rendered graphics never had a demosaicing stage. Read the result together with other forensic signals: check for clone regions, examine chromatic aberration consistency, or run the Authenticity Checker for a multi-signal verdict.
Can this detect AI-generated images?
Not on its own, and it should not be used that way. It is true that an image from a diffusion model or a GAN never passed through a Bayer sensor and so cannot carry the trace. The problem is the other side of it: a genuine camera photograph that has been resaved or resized cannot carry it either, and every sample photograph tested here scored no higher than a screenshot. So a missing trace does not separate synthetic from real — it separates untouched-from-sensor from everything else. Use it as one input alongside the AI Detector and the FFT Spectrum Analyzer, and treat a found trace as informative while treating its absence as inconclusive. Explore all 131 forensic and utility tools at Scanly's full toolkit.
This analysis runs entirely in your browser using a Web Worker thread — your images are never uploaded to any server, and they are read at full resolution rather than being downscaled first, because a rescale would remove the trace being measured. The result map can be downloaded as a PNG for reports. For a complete forensic workflow, start with the EXIF Checker to examine metadata before running pixel-level analysis. For device-level matching, the Camera Fingerprint (PRNU) tool identifies the specific sensor that captured an image. Learn more in our articles on detecting edited photos and complete forensics guide.