<commit_before>---
layout: page
title: Show Video Ads with DFP
description:
pid: 0
is_top_nav: yeah
top_nav_section: dev_docs
nav_section: prebid-video
---

<div class="bs-docs-section" markdown="1">

# Show Video Ads with DFP (Beta)
{: .no_toc}

In this tutorial, we'll show how to set up Prebid to show a video ad
from DFP.  We'll use the [Video.js](http://videojs.com/) player and
the AppNexus AST bidder, but the principles are the same across
different video players and video-enabled bidders.

* TOC
{:toc }

## Prerequisites

The code example below was built using the following libraries:

+ [video.js](http://videojs.com/) version 5.9.2
+ MailOnline's [videojs-vast-vpaid plugin](https://github.com/MailOnline/videojs-vast-vpaid) version 2.0.2

Also, you need to make sure to build Prebid.js with:

+ Support for at least one video-enabled bidder
+ Support for the `dfpAdServerVideo` ad server adapter, which will provide the video ad support

For example, to build with the AppNexus AST bidder adapter and the DFP
Video ad server adapter, use the following command:

```bash
gulp build --modules=dfpAdServerVideo,appnexusAstBidAdapter
```

For more information about how to build with modules, see the [Prebid.js project README](https://github.com/prebid/Prebid.js/blob/master/README.md#build-optimization).

Finally, your ad ops team needs to have set up line items in DFP
following the instructions at
[Setting up Prebid Video in DFP]({{site.baseurl}}/setting-up-prebid-video-in-dfp.html).

## Implementation<commit_msg>Fix bad link in 'Setting up Prebid Video in DFP'<commit_after>---
layout: page
title: Show Video Ads with DFP
description:
pid: 0
is_top_nav: yeah
top_nav_section: dev_docs
nav_section: prebid-video
---

<div class="bs-docs-section" markdown="1">

# Show Video Ads with DFP (Beta)
{: .no_toc}

In this tutorial, we'll show how to set up Prebid to show a video ad
from DFP.  We'll use the [Video.js](http://videojs.com/) player and
the AppNexus AST bidder, but the principles are the same across
different video players and video-enabled bidders.

* TOC
{:toc }

## Prerequisites

The code example below was built using the following libraries:

+ [video.js](http://videojs.com/) version 5.9.2
+ MailOnline's [videojs-vast-vpaid plugin](https://github.com/MailOnline/videojs-vast-vpaid) version 2.0.2

Also, you need to make sure to build Prebid.js with:

+ Support for at least one video-enabled bidder
+ Support for the `dfpAdServerVideo` ad server adapter, which will provide the video ad support

For example, to build with the AppNexus AST bidder adapter and the DFP
Video ad server adapter, use the following command:

```bash
gulp build --modules=dfpAdServerVideo,appnexusAstBidAdapter
```

For more information about how to build with modules, see the [Prebid.js project README](https://github.com/prebid/Prebid.js/blob/master/README.md#build-optimization).

Finally, your ad ops team needs to have set up line items in DFP
following the instructions at
[Setting up Prebid Video in DFP]({{site.baseurl}}/adops/setting-up-prebid-video-in-dfp.html).

## Implementation
{'fraction_non_alphanumeric': 0.09822866344605476, 'fraction_numerical': 0.0051529790660225444, 'mean_word_length': 4.596396396396396, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 4, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4142069', 'n_tokens_mistral': 1031, 'n_tokens_neox': 978, 'n_words': 376}