> For the complete documentation index, see [llms.txt](https://docs.hbwrapper.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.hbwrapper.com/key-values.md).

# Key-Values

**What is a key-value?** It's a small labelled piece of information the wrapper attaches to each ad request sent to Google Ad Manager (GAM). Each one has a short **Name** (the label GAM sees) and a **Value**. GAM uses these to decide which ad to show and to power your reporting — for example, you can report on how ads perform by device, by winning bidder, or by connection speed.

You don't have to set most of these up: the wrapper collects and sends them automatically. Some are controlled by settings in [Configuration](/configuration.md) (mostly under `targeting.*`); those are noted where relevant. New to the terms below (CPM, bidder, viewable, SafeFrame)? See the [Glossary](/glossary.md).

The current key-values are:

### Wrapper Version

**Description:** The major version of the wrapper.

**Name:** `wvr`

**Possible Values:**

* `3`: For the new wrapper.
* `2`: For the old wrapper.

### Prebid Winner Bidder (Prebid Specific)

**Description:** Prebid sends the winning bidder name to GAM.

**Name:** `hb_bidder`

**Possible Values:** The name of the bidder (e.g., `appnexus`, `pubmatic`).

### Prebid Winning Bid Value (Prebid Specific)

**Description:** Prebid sends the winning bid value to GAM.

**Name:** `hb_pb`

**Possible Values:** Depends on pricing, typically from `0.01` to `20.00`.

### Prebid Winning Format (Prebid Specific)

**Description:** Prebid sends the format type of the winning bid to GAM.

**Name:** `hb_format`

**Possible Values:** `banner`, `video`, `native`.

### Prebid Winning Source (Prebid Specific)

**Description:** Prebid sends the source of the winning bid to GAM.

**Name:** `hb_source`

**Possible Values:** `client`, `s2s`.

### Prebid Winning Sizes (Prebid Specific)

**Description:** Prebid sends the sizes of the winning bid to GAM.

**Name:** `hb_size`

**Possible Values:** The value of the sizes in `WIDTHxHEIGHT` format (e.g., `728x90`).

### Prebid Ad Category (Prebid Specific)

**Description:** Prebid sends the ad category of the winning bid to GAM, based on the IAB taxonomy, if disclosed by the bidder.

**Name:** `hb_acat`

**Possible Values:** The IAB taxonomy category ID of the winning bid, formatted as a string (e.g., `IAB1-18` for "News"). Categories follow the [IAB Content Taxonomy 1.0](https://github.com/katieshell/Taxonomies/blob/main/Content%20Taxonomies/Content%20Taxonomy%201.0.tsv).

### Prebid Advertiser Category Defined (Prebid Specific)

**Description:** Indicates whether the winning bid has advertiser category (`hb_acat`) data. Useful for reporting or targeting when the bidder disclosed an IAB category.

**Name:** `hb_acdef`

**Possible Values:** `0` (no ad category on the bid), `1` (bid has ad category).

### Prebid Ad Domain (Prebid Specific)

**Description:** Prebid sends the domain of the winning bid to GAM, if disclosed by the bidder.

**Name:** `hb_adomain`

**Possible Values:** The domain of the advertiser associated with the winning bid, formatted as a string (e.g., `example.com`).

### Prebid Ad Domain Defined (Prebid Specific)

**Description:** Indicates whether the winning bid has advertiser domain (`hb_adomain`) data. Useful for reporting or targeting when the bidder disclosed an ad domain.

**Name:** `hb_addef`

**Possible Values:** `0` (no ad domain on the bid), `1` (bid has ad domain).

### Prebid Winning Bid Cache Status

**Description:** Sends the cache status of the winning bid to GAM.

**Name:** `hb_cs`

**Possible Values:** `current`, `cached`, `storage`.

### Prebid Bid Density

**Description:** Sends the count of the number of bids received.

**Name:** `hb_bd`

**Possible Values:** The number of total bids.

### Flexible Safe Frames Signal

**Description:** Indicates whether SafeFrames are recommended for a specific impression based on the winning bid characteristics. The signal is set automatically by the wrapper according to configured rules that evaluate the bidder, advertiser domain, ad category, or ad unit. This key-value can be used in GAM line items or creative templates to conditionally enable SafeFrames.

**Configuration:** Set via `dfp.flexibleSafeFramesSignal` in config.json with conditions for bidders, advertiser domains, ad categories, or specific ad units.

**Name:** `hb_sframe`

**Possible Values:**

* `0`: SafeFrames not recommended for this impression
* `1`: SafeFrames recommended for this impression

### Price Range Bucket

**Description:** Provides a way to report based on a range of prices, rather than a specific CPM, allowing for more flexible and efficient reporting.

**Name:** `hb_rpb`

**Possible Values:** A string representing a price range, with increments of 0.10. The format is `[lower_bound]-[upper_bound]`, where bounds are formatted to two decimal places and separated by a hyphen (e.g., `0.50-0.60`). If a bid has a CPM of 1.23, the `hb_rpb` key will have the value `1.20-1.30`.

**Notes:** To use this key, it must be added to the `allowTargetingKeys` array in your Prebid configuration:

```javascript
{
   "targetingControls": {
     "allowTargetingKeys": ["hb_pb", "hb_rpb", "hb_deal"]
   }
}
```

### Adunit Not Hidden

**Description:** Checks if the adunit is hidden through HTML/CSS.

**Name:** `anh`

**Possible Values:**

* `true`: Adunit is not hidden.
* `false`: Adunit is hidden.
* For rich media formats, the name of the format (e.g., `adhesion`, `sticky`, `interstitial`, `peel`).

### PreRender Status

**Description:** Checks the Chrome prerender status.

**Name:** `prst`

**Possible Values:**

* `no`: The page is not prerendered.
* `before`: The page is prerendering but not activated yet.
* `after`: The page was prerendered and is now activated.

### Page Navigation Type

**Description:** Represents how the page navigation was initiated. Can be enabled in `config.targeting.pageNavigationType`.

**Name:** `pnType`

**Possible Values:**

* `reload`: Page was reloaded/refreshed.
* `push`: New navigation entry (normal navigation).
* `replace`: Current entry was replaced.
* `traverse`: Navigation through history (back/forward).
* `navigate`: Normal navigation (clicking a link, typing a URL, etc.).
* `back_forward`: Navigation via browser back/forward buttons.
* `prerender`: Page was prerendered.
* `reserved`: Reserved value.
* `unknown`: When navigation type cannot be determined.

### Wrapper Iframe Environment

**Description:** The wrapper checks if it is loaded within an iframe and what type of iframe.

**Name:** `wie`

**Possible Values:**

* `top`: Wrapper is not in an iframe.
* `friendly`: Wrapper is in a friendly iframe.
* `cross`: Wrapper is in a cross-domain iframe.
* `safe`: Wrapper is in SafeFrames.

### Wrapper Re-write Global Conflict

**Description:** Detects if there is a conflict when the wrapper attempts to re-write the default Prebid global variable.

**Name:** `wrc`

**Possible Values:**

* `nc`: No Conflict.
* `fr`: Forced Re-write set, but no conflict.
* `cr`: Conflict Re-write detected.

### Tab In Focus

**Description:** Detects if the browser tab/window where the ad is displayed is in focus.

**Name:** `tif`

**Possible Values:** `true`, `false`.

### Refresh Iteration Counter

**Description:** Counts the number of refreshes for an adunit.

**Name:** `refresh_count`

**Possible Values:** An integer representing the refresh count.

### Refreshed Inventory Boolean

**Description:** Tracks whether the inventory has been refreshed.

**Name:** `refreshed`

**Possible Values:** `true`, `false`.

### Refreshed Accelerated Seconds

**Description:** Represents the number of seconds the refresh was accelerated by.

**Name:** `ras`

**Possible Values:** From `0s` to `30s`.

### Display Advertisers History

**Description:** Logs all Google Ad Manager (GAM) advertiser/company IDs that displayed an ad.

**Name:** `dah`

**Possible Values:** A list of GAM advertiser IDs.

### Last Advertiser Displayed

**Description:** Logs the last Google Ad Manager (GAM) advertiser/company ID that displayed an ad.

**Name:** `lad`

**Possible Values:** The GAM ID of the last advertiser displayed.

### Last User Interaction

**Description:** The time elapsed since the last user interaction (click, touch, scroll, visibility change, resize).

**Name:** `lui`

**Possible Values:**

* From `0s` to `59s`.
* From `1m` to `59m`.
* `1h` for interactions exceeding 59 minutes.

### Session Depth

**Description:** The number of pageviews made in the current session.

**Name:** `sesdepth`

**Possible Values:** An integer representing the pageview count for the session.

### GAM Library Load Time

**Description:** The time it takes for the GAM library to load, relative to the Wrapper Load Time.

**Name:** `gpt_l`

**Possible Values:** From `0` to `10000` in `100` increments.

### Wrapper Load Time

**Description:** The time it takes for the Wrapper to load, relative to page navigation.

**Name:** `wrap_l`

**Possible Values:** From `0` to `10000` in `100` increments.

### Page Load Time

**Description:** The time it takes for the page to load. This is important as the first ad processing occurs upon page load.

**Name:** `page_r`

**Possible Values:** From `0` to `10000` in `100` increments.

### Wrapper Analytics Auction Init

**Description:** The time it takes for the auction to be initiated, relative to the Wrapper Load Time.

**Name:** `waai`

**Possible Values:** From `0` to `10000` in `100` increments.

### Wrapper Analytics Auction End

**Description:** The time it takes for the auction to end, relative to the auction initiation.

**Name:** `waae`

**Possible Values:** From `0` to `10000` in `100` increments.

### Wrapper Analytics Bidders Timeout

**Description:** Identifies bidders that timed out, relative to Prebid's detection.

**Name:** `wabt`

**Possible Values:** The name of the bidders.

### Wrapper Analytics Bidders Timeout Real

**Description:** Identifies bidders that timed out before bids were sent to GAM.

**Name:** `wabtr`

**Possible Values:** The name of the bidders.

### Connection DownLink

**Description:** The connection downlink speed.

**Name:** `cndl`

**Possible Values:**

* `0`: Unknown.
* `0.1`: Under 1MB.
* `1`: 1-9.99 MB.
* `10`: 10-99.99 MB.
* `100`: 100-999.99 MB.
* `1000`: >= 1000 MB.

### Connection RTT

**Description:** The connection Round Trip Time speed.

**Name:** `cnrtt`

**Possible Values:**

* `0`: Unknown.
* `10`: <= 10ms.
* `100`: <= 100ms.
* `900`: <= 900ms.
* `1000`: >= 1000ms.

### Connection Type

**Description:** The connection type.

**Name:** `cntp`

**Possible Values:** `na`, `bluetooth`, `cellular`, `ethernet`, `none`, `wifi`, `wimax`, `other`, `unknown`.

### Connection Effective Type

**Description:** The connection speed type.

**Name:** `cnet`

**Possible Values:** `na`, `slow-2g`, `2g`, `3g`, `4g`, `5g`.

### Connection Save Data

**Description:** Indicates if the connection has save data enabled.

**Name:** `cnsd`

**Possible Values:** `true`, `false`.

### Page Ad Density PreRequest

**Description:** Represents ad density before requests, based on the biggest ad size available.

**Name:** `padpr`

**Possible Values:** From `0` to `100`.

### Page Ad Density

**Description:** Represents ad density after ads have been rendered.

**Name:** `pad`

**Possible Values:** From `0` to `100`.

### Google Ad Manager Identification

**Description:** Checks if the GAM cookie, used to identify the user, exists.

**Name:** `gads`

**Possible Values:** `true`, `false`.

### Cookies Enabled

**Description:** Checks if the browser allows third-party cookies.

**Name:** `cookieEnabled`

**Possible Values:** `true`, `false`, `na`.

### User Identifications Services/Providers

**Description:** The wrapper checks which User Identification services detected the user.

**Name:** `uids`

**Possible Values:** Name of the User Identification services.

### User Identifications Services/Providers Count

**Description:** The wrapper counts how many User Identification Services detected the user.

**Name:** `uids_c`

**Possible Values:** The number of User Identification services.

### Topics API Interests

**Description:** The interests according to Topics API.

**Name:** `topicsapi`

**Possible Values:** Topics API Taxonomy.

**Notes:** For more information on how topics are curated and selected, refer to [Google Privacy Sandbox Topics](https://developers.google.com/privacy-sandbox/relevance/topics#manually-curated).

### Individual User Identifications Services/Providers

**Description:** Sets a key-value for each configured User Identification Service/Provider, indicating if the user has been identified.

**Name:** Name of the Service/Provider configured.

**Possible Values:** `true`, `false`.

### UTMs utm\_campaign

**Description:** The wrapper checks if UTMs are set in the URL and sends the `utm_campaign` value to GAM.

**Name:** `utm_campaign`

**Possible Values:** Value of the `utm_campaign` parameter.

### UTMs utm\_source

**Description:** The wrapper checks if UTMs are set in the URL and sends the `utm_source` value to GAM.

**Name:** `utm_source`

**Possible Values:** Value of the `utm_source` parameter.

### UTMs utm\_medium

**Description:** The wrapper checks if UTMs are set in the URL and sends the `utm_medium` value to GAM.

**Name:** `utm_medium`

**Possible Values:** Value of the `utm_medium` parameter.

### UTMs utm\_content

**Description:** The wrapper checks if UTMs are set in the URL and sends the `utm_content` value to GAM.

**Name:** `utm_content`

**Possible Values:** Value of the `utm_content` parameter.

### Device

**Description:** Checks the device type.

**Name:** `device`

**Possible Values:** `desktop`, `tablet`, `mobile`.

### Browser

**Description:** Checks the browser.

**Name:** `browser`

**Possible Values:** `edge`, `chrome`, `firefox`, `safari`, `opera`, `ie`, `other`.

### Operating System

**Description:** Checks the operating system.

**Name:** `os`

**Possible Values:** `linux`, `mac`, `windows`, `other`.

### Browser Language Code

**Description:** Checks the browser language code.

**Name:** `blc`

**Possible Values:** A comprehensive list of language codes (e.g., `en-US`, `fr-CA`, `zh-TW`).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.hbwrapper.com/key-values.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
