npm / pixelmatch
pixelmatch
What changed in pixelmatch 7 to 8, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-18.
1 breaking3 new APIs and options1 performance1 behavior and defaults3 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli initpixelmatch 85 changes
Breaking changes 1
Color comparison now uses OKLab and HyAB instead of YIQ, changing diff counts to better match perceived color differences.
New APIs and options 2
Adds a per-pixel mask for skipping areas such as timestamps or animations.
Returns the largest number of differing pixels in any N×N square instead of the total count, helping distinguish compact changes from scattered noise.
Fixes and other changes 2
Anti-aliasing detection is more reliable on images with transparency.
Colors that differ only in transparency are much less likely to be missed.
pixelmatch 74 changes
New APIs and options 1
Controls whether semi-transparent pixels are blended against a checkerboard pattern (true, the default) or plain white (false, the pre-v7 behavior) when comparing images.
Performance 1
Performance improves by approximately 8%.
Behavior and default changes 1
Antialiasing checks are skipped when includeAA is true.
Fixes and other changes 1
Errors on image size mismatch are clearer.