Identical screenshots are now compared by their hash, and for free
Most pages look the same from one deploy to the next. deploydiff now recognises two identical captures by their hash and answers without comparing a single pixel: nothing to wait for, nothing charged.
Visual regression testing has an awkward base case. You deploy, every page is captured and compared with its reference, and for most of them the answer is the same: nothing changed. The pricing page nobody touched, the docs between two releases of something else, the footer that has looked the same for months.
A pixel comparison is real work: an isolated environment starts, decodes both screenshots, compares them pixel by pixel and draws a diff image. When nothing changed, all of that work only confirms what the two files already said.
Same bytes, same pixels
A page that has not changed, captured by the same browser at the same size, usually produces the same file, byte for byte. deploydiff now takes a SHA-256 of every screenshot as it stores it. When the two captures of a comparison carry the same hash, they are the same image, and the result is already known: a 100% match, which passes whatever thresholds the page is held to.
So no environment is started and neither screenshot is downloaded. The answer is there as soon as the comparison is picked up, instead of after an environment has booted.
The check only works in one direction, and that is what makes it safe. The same hash means the same pixels. Different hashes do not mean different pixels: two screenshots that look the same can be encoded differently. In that case the comparison runs pixel by pixel, as before. A miss costs a normal comparison. It never gives a wrong verdict.
What it costs now
Nothing. A comparison between two identical captures is recorded at $0, since no computation ran, and on the free Discovery plan it uses none of the monthly allowance. It stores no diff image either, so there is no image storage to pay for.
When the screenshots do differ, nothing changes: the comparison runs in its own environment, shows you exactly what moved, and is billed at the published rates.

What you will see

- On the comparison's page, "Identical — the two captures are the same image (same hash)" takes the place of the diff image, and the cost card says why nothing was charged.
- In the API, a finished diff carries
compared_by, either"hash"or"pixels", and each capture's screenshot carries itssha256. - After a cleanup, an identical comparison keeps its result, a 100% match, but no picture once its captures are deleted. There was nothing to see in it.
There is nothing to turn on: it works on every plan. The details are in the diff batches documentation.
See what changed on every deploy
Start on the free Discovery plan, no credit card needed.

