Tech Knows You a blog about online advertising

The writing auctions programmatic

The 100-millisecond auction

Anatomy of a single ad impression, from the first byte of HTML to a cleared trade — all before the page finishes painting.

By the editor 5 min read zero ads on this page

Say you tap a link to a recipe — a promising one, brown butter involved. Your browser asks a server for the page, and the first bytes of HTML start down the wire. Somewhere in the head of that document, before the ingredients, before the photograph of the finished thing, a small piece of code wakes up with one job: to sell the fact that you have arrived. It has roughly a hundred milliseconds to do it.

That number is not a figure of speech. The paperwork about to be drafted on your behalf carries a field called tmax, which tells every would-be bidder precisely how long it has to answer; the OpenRTB standard leaves the value to the exchange, and in practice the window commonly runs 100 to 300 milliseconds.1 Answer late and your bid is binned unread. What follows is one impression — one advert slot, on one page, loading once — walked through the plumbing against the clock.

0 ms: the starting gun

The publisher — the recipe site — has drawn rectangles into its layout and named them: a leaderboard above the fold, a medium rectangle beside the method. Each empty rectangle is inventory, and the moment you request the page it becomes perishable: sellable for the next tenth of a second, worthless after. As the HTML parses, the publisher’s ad code fires. On much of the open web this is a header-bidding wrapper such as Prebid.js, which offers the slot to several exchanges at once rather than queueing them politely, one by one, down a waterfall.4

The wrapper’s messages go to supply-side platforms — SSPs — firms whose entire trade is representing publishers’ empty rectangles to the world’s buyers. Each SSP (these days usually the same company as the exchange it feeds) drafts the formal offer: a bid request in the OpenRTB format, the lingua franca of the machinery, maintained by the IAB Tech Lab.1

What is in a bid request? The page URL. The slot’s size and position. Your device’s make, operating system and browser. Your approximate location, worked out from your IP address. An identifier, if one can be had — a cookie, a mobile advertising ID, an identity graph’s best guess — and, depending on the arrangements upstream, audience labels: in-market for cookware, frequent flyer, probable parent.

The bid request is your dossier, abridged for speed.

The exchange fans this envelope out to demand-side platforms — DSPs — the buying desks that hold advertisers’ budgets and their standing orders. Dozens of companies can receive a copy of any given request, which means dozens of companies are told, hundreds of times a day, where you are and what you are reading.3 The Irish Council for Civil Liberties, totting up these broadcasts, called the system the biggest data breach ever recorded.2

40 ms: pricing you

Inside each DSP, your abridged dossier meets the order book. Campaigns sit there like standing queries, waiting for someone shaped like you: an airline wants people who searched for flights this month; a cookware brand is retargeting everyone who abandoned a basket; somebody, always, simply wants adults 25 to 54 in your city.

Each matching campaign is checked against its own rules. Frequency cap: has this person already seen the ad four times today? Brand safety: is the page agreeable company? Pacing: is the budget burning too fast for this hour? Whatever survives gets priced — an estimate of the chance you will notice, click, eventually buy, folded into a bid expressed as a CPM, a cost per thousand impressions. In this arithmetic you are a thousandth of a line item.

None of this is contemplation. There is no time to think, so the thinking is done in advance: the models are trained overnight, the audience lists sit in memory, and the whole evaluation runs as a lookup with sums attached. Speed is not a feature of the system; it is the system.

100 ms: the hammer

The bids come home. Late ones are discarded without ceremony — tmax is tmax — and the exchange runs the auction over whatever arrived in time. For most of programmatic’s history this was a second-price affair, the winner paying a whisker more than the runner-up; by the end of 2019 the major exchanges had switched to first-price, where you pay what you bid.5 The winner must still clear the publisher’s floor price, and may still be weighed against directly sold campaigns in the publisher’s ad server before the rectangle is truly theirs.

Then the prize. The winning creative — the advert itself — is fetched and rendered into the slot, inside a cross-origin iframe the host page cannot see into. A win notice pings back so the buyer can log the spend. The recipe’s photograph finishes decoding, the text settles, and the page is simply there. The trade opened, cleared and settled before the page finished painting. You noticed nothing, which was the point.

Multiply by everything

Now widen the shot. That one page held several rectangles, each auctioned separately. Every page view, every app screen, every pull-to-refresh runs the same drill, and an auction that ends in a tenth of a second can be held almost without limit: industry accounts have the large exchanges fielding hundreds of billions of bid requests a day. The ICCL’s tally of the resulting broadcasts came to 178 trillion a year across the US and Europe, with the average American’s activity and whereabouts shared 747 times a day.2

178 trillion

real-time bidding broadcasts of people’s data per year across the US and Europe, by the ICCL’s count

The money is almost easier to picture than the tempo. Digital advertising worldwide moves roughly $25,000 every second, but a second is a geological age here; the machine experiences it as ten full auction cycles. And each individual auction is honest in the narrowest sense — a real request, real bids, a clearing price, a settlement. Whether your dossier should have been in the envelope at all is a different question, and a different essay.

Speed is not a feature of the system; it is the system.

It is also, I should admit, how the lights stay on here. This page carries no ads — none of the essays do — but the four labelled rectangles on our landing page ran this exact drill as it loaded, cleared before its first paragraph painted. The hundred-millisecond auction is not a special occasion. It is the resting heartbeat of the web, and you have been standing on the trading floor all along.

Sources & further reading

  1. IAB Tech Lab, OpenRTB specification — the bid-request standard, including the tmax timeout field. github.com/InteractiveAdvertisingBureau/openrtb
  2. Irish Council for Civil Liberties, The Biggest Data Breach (2022) — RTB broadcasts data on people in the US and Europe 178 trillion times a year; the average American is exposed 747 times a day. iccl.ie
  3. Electronic Privacy Information Center, What is Real Time Bidding? — plain-language explainer of the bid-request broadcast and its privacy stakes. epic.org
  4. Prebid.org, Prebid documentation — the open-source header-bidding wrapper used across the open web. docs.prebid.org
  5. AdExchanger, The Programmatic Auction Is Changing In Real Time — Here’s How — on the industry’s shift from second-price to first-price auctions. adexchanger.com