Compression Demos
Encodes values as differences from the previous value. Works best on sorted or slowly-changing data where differences are small numbers.
ENCODED OUTPUT.Sorted Example or Random Example to compare how differently the two datasets compress.Values, Max Delta, Avg Delta, and Match summarize the sequence and confirm the round-trip.Copy Encoded to grab the delta list, or Copy Decoded for the reconstructed values.Clear any time to reset the box and start over.Counters, gauges, and timestamps change slowly, so consecutive differences stay small — the reason time-series databases like Prometheus and Gorilla use delta-of-delta encoding.
Sorted lists, IDs, and offsets produce small, non-negative deltas that compress far better than the raw values they replace.
Delta encoding is a common first step before variable-length or run-length coding. Small deltas are what make those later steps effective.
Pairing small deltas with variable-length integer encoding is a standard technique in binary protocols and columnar storage formats.
The DECODED (RECONSTRUCTED) output rebuilds the original values, and the Match stat reads YES to confirm nothing was lost.
Everything runs in your browser. Nothing is uploaded, logged, or sent to a server — safe for sensitive numeric data.
It stores the first value unchanged, then each following value as the difference from the one before it. For example, [10, 25, 40] becomes [10, 15, 15].
By cumulative sum: start with the first value, then keep adding each delta. 10 → 10+15=25 → 25+15=40.
It acts as the anchor. Without a starting point, the list of differences can't be converted back into absolute values.
On random or jumpy data the deltas can be as large as — or larger than — the original values, so there's little to gain. It shines on sorted or slowly-changing data.
Yes. Negative numbers are handled, and hex bytes can be given with a 0x prefix (for example 0xFF). Values are separated by commas, spaces, or newlines.
No. The DECODED (RECONSTRUCTED) output always rebuilds the exact input, and the Match stat reads YES when the round-trip is perfect.
Never. Encoding, decoding, and stats all run locally in JavaScript. Nothing is sent to, stored on, or logged by any server.