Prebid docs - browse
Prebid/Concepts/How header bidding works
CONCEPT

How header bidding works

Header bidding is a sequence, not a product. Prebid runs an auction in the page, then the ad server uses those prices in its own decision.

Plain English

The page loads Prebid and the ad server tag. For Google Ad Manager, the usual integration holds the first ad request so line items do not run before Prebid has written its keys.

Prebid calls the bidders on each ad unit together. When the bids are back, or the auction timeout fires, it writes targeting for the bids that made it. The ad server is called after that. Its line items - direct, house, or Prebid price buckets - compete as they always have.

If a Prebid line item wins, Prebid renders that bidder's creative. If something else wins, the Prebid bid is unused. A response that arrives after the timeout is not part of the ad server's decision. Prebid's troubleshooting guide says this directly.

How it shows up in pbjs

disableInitialLoad holds GAM. requestBids starts the auction. setTargetingForGPTAsync copies hb_ keys onto the slots. googletag.pubads().refresh() is the ad server call, not a second creative refresh. The full example also sets a failsafe timer outside Prebid, in case the library never calls back. That timer is separate from bidderTimeout. See bidder timeout.

Prebid.js basic examplefrom prebid.org
googletag.cmd.push(function () {
  googletag.pubads().disableInitialLoad();
});

pbjs.que.push(function () {
  pbjs.addAdUnits(adUnits);
  pbjs.requestBids({ bidsBackHandler: sendAdServerRequest });
});

function sendAdServerRequest() {
  if (pbjs.initAdserverSet) return;
  pbjs.initAdserverSet = true;
  googletag.cmd.push(function () {
    pbjs.setTargetingForGPTAsync();
    googletag.pubads().refresh();
  });
}

When it helps, when it hurts

Helps

You can see each bidder's price before GAM decides, and you can tell a slow partner from a partner who never answers. The auction timeout is the knob that decides how long the page is willing to wait.

Hurts

If the ad server runs before targeting is set, header bidding never enters the choice. If a later refresh sends the same hb_ keys without a new auction, the same bid can render again. Prebid documents that as stale rendering. A timeout copied from another site is a guess, not a setup.

What bidtune tests here

Autopilot does not reimplement this sequence. It tests changes around it: how long the auction waits, what floor is sent, whether a later auction may reuse a bid, and how refresh is paced. Those are the decision docs linked below.
The comparison for the whole setup is the holdback, which keeps the sequence you have now.
The 10% holdback keeps your current configuration. A test runs on 30% of optimized traffic, for at least 72 hours and 2,000 sessions in each arm, and no longer than 14 days. bidtune keeps the change only after the capped session read is better at two daily checks.
How bidtune tests itTHE RULES
A test takes 30% of optimized traffic
Judged against its own control. The 10% holdback never changes.
10% holdback60% control30% test
sessions per arm2,000minimum runtime72hdecides onrev / session