HyperLogLog estimates how many distinct items are in an enormous dataset without keeping a record of every item. That lets websites and other systems count unique visitors using a tiny amount of memory, with typical estimates reported as less than 1 per cent off.
Watch Desk analysis
What happened
Scientific American explains the algorithm through a coin-flipping game: keep track of the longest run of tails before a head. A long run is rare, so seeing one gives you a rough clue about how many rounds were played. HyperLogLog adapts that idea to count distinct visitors.
In practice, an algorithm hashes an identifier into a repeatable string of bits. It tracks patterns in those bits rather than storing a roster of everyone who has visited. Returning visitors produce the same hash, so they do not inflate the estimate. To limit the effect of an unusually long streak, the method divides visitors into many groups and combines the estimates, using a harmonic mean to reduce the influence of outliers.
Why it matters
Counting unique visitors exactly can mean retaining a huge list of identifiers. HyperLogLog trades a small amount of accuracy for a dramatic saving in memory, making estimates practical at very large scale. Scientific American says the method is used in tools including Google Analytics, and also in areas such as cybersecurity and genomics.
That is more than a clever bit of maths: the same pattern helps systems estimate distinct items without keeping a person-by-person ledger. The trade-off is that the result is an estimate, not an exact headcount.
Our read
This is an unusually satisfying computing idea: a tiny statistical clue stands in for a mountain of records. The coin analogy makes the intuition accessible, while the hashing and grouping explain how the trick becomes useful in real systems. The reported accuracy is impressive, but it is still an estimate, and its usefulness depends on the job tolerating that margin.
What to watch
- Where analytics and infrastructure tools use HyperLogLog or related algorithms.
- Whether a task needs an exact count or can use a compact estimate.
- How systems handle unusual data that could skew a count.
Discussion spark: For website analytics, is an estimate that saves enormous amounts of memory a fair trade, or should providers prioritise exact counts even if that means keeping more data?
Sources and evidence
- The coin-flipping trick that counts the Internet (9 November 2026, 15:15 UTC)
Watch Desk is operated by WittyWires as an independent cross-cutting AI news tracker. It does not speak for the organisations or people it covers.