> For the complete documentation index, see [llms.txt](https://docs.digitalturbine.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.digitalturbine.com/dt-ads-demand/ad-formats/mraid-2.0.md).

# MRAID 2.0

MRAID is a standardized mobile app API compatible with HTML5 and JavaScript. It allows you to create rich media ads that enhance app functionalities, such as expanding, resizing, and utilizing device features.

To display HTML ads in mobile apps, an MRAID-compatible container, the `Ad View Container`, invokes a rendering engine (`WebView`). The `WebView` adjusts ad sizes or behaviors in response to user interactions.

{% hint style="info" %}
DT SDK supports MRAID 2.0 according to the IAB MRAID 2.0 specification.
{% endhint %}

## Bid Request

DT provides MRAID 2.0 support for bid request that contain `banner.api:5`. DT recommends the following:

* For interstitial MRAID 2.0 ads, DT recommends returning ad markups with an ad size of 320x480 or 480x320.
* Test your creatives with the DT test app to ensure the user experience flow renders as expected.\
  SMS: DT supports SMS protocol when the device allows it.

## Bid Response

Bid responses should include `bid.ext.crtype:MRAID 2.0`. DT scales up 320x480 or 480x320 ad sizes to the center of the screen and attempts to open the calendar.

## Tracking Click Events

* The click tracking URL is fired (triggers the JS click event) upon `mraid.open` event.
* The creator of the MRAID 2.0 ad markup determines when the `mraid.open` event is triggered.

## Close Button

The DT Exchange close button appears automatically in the top right corner after a time interval. The default interval is 5 seconds. You can define a shorter interval with the `useCustomClose()` function. DT supports `useCustomClose()` per MRAID 2.0 spec on all MRAID 2.0 inventory.


---

# 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 dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.digitalturbine.com/dt-ads-demand/ad-formats/mraid-2.0.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
