Google Ads Moves Fraud Graph Detection to Spanner Graph, Cutting Multi-Hop Queries to Milliseconds
Google says its Ads anti-abuse platform now runs multi-hop graph queries on Spanner Graph in real time, replacing hour-long batch jobs. The move targets coordinated fraud rings across a graph of over 500 billion nodes.
TL;DR
- Google's Ads anti-abuse platform now runs multi-hop graph queries in real time on Spanner Graph.
- The previous batch system on MapReduce took hours; the new queries return in sub-second to single-digit millisecond latency, according to Google.
- Because the data already lived in Spanner, no migration was needed; graph definitions sit on top of existing relational tables.
The problem: fraud works as networks
Fraud in digital advertising is rarely a single bad account. Google describes bad actors hiding behind residential proxies and synthetic identities, and sharing payment methods, domains and accounts. Each signal can look harmless on its own, so checks that evaluate signals one at a time miss the pattern. Google's point is that the unit of detection needs to be the whole coordinated cluster, not an isolated indicator.
The timing problem was just as serious. The earlier system ran on offline MapReduce batch processing. Google says tracing multi-hop relationships there required repeated, expensive joins across distributed stages, which produced hours-long latencies. For a live malware campaign, that delay leaves room for a lot of damage.
Why Spanner Graph
The team needed a store that could ingest live signals from many sources through pub/sub streams while keeping global transactional consistency and answering multi-hop traversals quickly. Google chose Spanner Graph, which lets teams define property graphs directly over relational tables. Since Ads' core transactional and entity data already sat in Spanner, the team did not need to move data or stand up a separate graph database. Google says most use cases moved over within weeks.
Queries are written in ISO Graph Query Language (GQL), a standard pattern-matching language for graphs. Engineers can query the same tables used by the rest of the system instead of maintaining custom traversal code. Google also says the queries can combine full-text keyword search and vector similarity search.
Scale and what it is used for
Google says the platform now works as a single, Google-wide defense layer over a live graph of more than 500 billion nodes and 1 trillion edges. According to the post, it is a primary source of detection signals for ad policy enforcement. Google lists three main uses: uncovering networks behind click fraud, click farms and invalid traffic; catching public-figure impersonation, account takeovers, cloaking and landing-page malware before campaigns scale; and correlating billing and identity data to stop banned offenders from opening new accounts.
The same post cites other companies using Spanner Graph, including Target, PayPal, Equifax and Yahoo, but these are Google's own claims and the post does not include independent measurements of them.
Context: the scale of the threat
Google cites a NASDAQ Global Financial Crime Report estimate of nearly $580 billion in global fraud losses for 2025. It also says that in 2025 it blocked or removed more than 8.3 billion policy-violating ads and suspended 24.9 million advertiser accounts. These figures come from Google and a third-party report it cites; they have not been independently verified here.
Why it matters
For most teams, the main lesson is architectural. If your operational data already lives in a relational database and you need relationship queries, a graph layer over existing tables may avoid a separate pipeline and its synchronization risks. Google's case also shows why batch joins become a bottleneck for multi-hop questions, which grow expensive as the number of hops and entities increases.
The claims are Google's own and come from a vendor-facing blog post, so teams evaluating Spanner Graph should check latency and cost against their own workloads. Developers who want to try it can start with the codelabs Google links to.
Sources
This article was written by Blozhik from the reporting below. Read the originals for full detail.
GoHow Spanner Graph detects ads fraud and abuse at Google at multi-billion node scaleGoogle Cloud Blog