CFA Pattern Analysis
Analyze Bayer color filter array demosaicing artifacts. Real camera images retain periodic patterns from the sensor's CFA. Edited, composited, or AI-generated regions lose these patterns.
800+ images analyzed for CFA patterns
Drag & drop a file here, Ctrl+V to paste, oror
Bayer Pattern Detection
Camera sensors use a Bayer CFA mosaic (RGGB) to capture color. The demosaicing process leaves characteristic periodic artifacts in the color difference channels — a fingerprint of camera-original imagery.
Editing Detection
Image editing tools like Photoshop, GIMP, or AI generators disrupt or eliminate CFA patterns. Regions that have been cloned, pasted, inpainted, or generated from scratch will show weaker periodicity than untouched areas.
Web Worker Processing
All analysis runs client-side in a background Web Worker. Your image never leaves your device. Adjustable grid resolution lets you balance detail against processing time for large images.
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. This interpolation leaves subtle periodic patterns in the color difference signals (red minus green, blue minus green). These patterns act as a fingerprint of camera-original imagery. For broader metadata analysis, check your photo with the EXIF Checker or examine sensor noise with the Noise Analysis tool.
How CFA analysis detects editing
When an image region is edited — cloned, inpainted, pasted from another source, or generated by AI — the demosaicing periodicity is disrupted or absent entirely. This tool measures 2×2 autocorrelation in the R-G and B-G channels per grid block. Camera-original blocks show characteristic checkerboard correlation; manipulated blocks do not. Unlike ELA which detects recompression, CFA analysis targets the fundamental sensor-level signature of real photographs, making it effective even against high-quality forgeries that survive compression tests.
Limitations and edge cases
CFA analysis has limitations. Flat or low-texture regions (sky, solid walls) lack enough color variation for reliable periodicity measurement — these appear gray on the heatmap. Heavy JPEG compression, aggressive noise reduction, or camera-internal processing can weaken CFA patterns even in genuine photos. Screenshots, scanned documents, and rendered graphics never had a CFA stage, so they will always show zero periodicity. Use CFA analysis alongside other forensic signals: check for clone regions, examine chromatic aberration consistency, or run the Authenticity Checker for a multi-signal verdict.
CFA vs AI-generated images
AI-generated images from diffusion models (Stable Diffusion, Midjourney, DALL-E) and GANs never passed through a physical camera sensor, so they completely lack Bayer demosaicing artifacts. This makes CFA analysis a strong complementary signal for AI detection alongside the AI Detector and FFT Spectrum Analyzer. A genuine camera photo will show periodic CFA patterns; a fully synthetic image will not. Explore all 76 forensic and utility tools at Scanly's full toolkit.
CFA pattern analysis runs entirely in your browser using a Web Worker thread — your images are never uploaded to any server. The analysis heatmap 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.