You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: adops/creative-considerations.md
+5-1Lines changed: 5 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -30,10 +30,14 @@ The first decision you’ll need to make when it comes to creatives (with the ex
30
30
31
31
The big advantage to using the PUC is that it’s the simplest approach to configuring Prebid in your ad server. It provides a robust mechanism that can be used across several formats, platforms, devices, and ad servers.
32
32
33
-
The primary disadvantage to using the PUC is that it takes an extra fetch to load the PUC file vs doing everything inline to the creative. Also, in version 1.14.1 and earlier of the PUC, loading a “universal” creative means that more bytes are loaded than are actually necessary for the display of a single creative. This all leads to a very slight performance penalty.
33
+
The primary disadvantage to using the PUC is that it takes an extra fetch to load the PUC file vs doing everything inline to the creative. Also, loading a “universal” creative means that more bytes are loaded than are actually necessary for the display of a single creative. This all leads to a slight performance penalty.
34
34
35
35
You’ll need to determine whether the ease of implementation is worth the small performance penalty.
36
36
37
+
## Prebid.js dynamic creatives
38
+
39
+
If you have line items that target only browsers running Prebid.js, you can use [dynamic creatives](/adops/js-dynamic-creative.html) to avoid the PUC performance penalty but keep the same ease of setup and maintenance. The disadvantage of this approach is that it does not support platforms that do not run Prebid.js, such as AMP or mobile apps.
40
+
37
41
## Where to Host the PUC
38
42
39
43
If you choose to use the Prebid Universal Creative, you'll need to decide where to load it from:
For line items that target browsers only, you may use Prebid.js dynamic creatives as an alternative to [Prebid Universal Creative](/overview/prebid-universal-creative.html). The former provides slightly better performance and ease of use, but relies on Prebid.js, meaning that it does not support non-JS use cases (such as mobile apps or AMP).
17
+
18
+
## Comparison vs PUC for Prebid.js
19
+
20
+
A creative set up to use Prebid Universal Creative:
21
+
22
+
- loads a separate script, typically from a CDN; the script contains various rendering routines, including some specific to Prebid.js;
23
+
- if the script determines that the ad render was initiated by Prebid.js, it retrieves from it information about the winning bid and renders it;
24
+
- requires different setups for different use cases (such as banner vs native).
25
+
26
+
A Prebid.js dynamic creative:
27
+
28
+
- does not load any additional script - it's instead set up with a small block of inline Javascript;
29
+
- it expects to always find Prebid.js, retrieving from it information about the winning bid _and_ the rendering logic to use for it;
30
+
- uses the same setup for all cases - but does not work when the render is not initiated by Prebid.js.
31
+
32
+
## How to use
33
+
34
+
{: .alert.alert-warning :}
35
+
Dynamic creatives require Prebid.js version 8.36 or higher.
36
+
37
+
Set up the creative following [this example](https://github.com/prebid/Prebid.js/blob/master/integrationExamples/gpt/x-domain/creative.html). If you are not using GAM, replace the macros in the second `script` tag with appropriate equivalents.
38
+
39
+
To render native ads, you also need to include the [nativeRendering](/dev-docs/modules/nativeRendering.html) module in your Prebid.js bundle.
description: Render native bids with renderAd or dynamic creatives
6
+
module_code : nativeRendering
7
+
display_name : Native Rendering
8
+
enable_download : true
9
+
sidebarType : 1
10
+
---
11
+
12
+
# Native rendering module
13
+
14
+
This module enables rendering of native ads through [pbjs.renderAd](/dev-docs/publisher-api-reference/renderAd.html) or [dynamic creatives](/adops/js-dynamic-creative.html).
15
+
16
+
There's no configuration necessary except for installing the module; once included, you may use those rendering methods for native bids. If _not_ included, rendering native ads is only supported through [Prebid Universal Creative](/overview/prebid-universal-creative.html).
Note that as of PUC v1.15, the recommended way of loading the creative
36
36
in the ad server involves using the `hb_format` ad server key-value. Before 1.15, the ad server needed to load creative.js which covered banner and outstream video, or native-render.js for native. 1.15 simplifies this
@@ -77,6 +77,14 @@ While Prebid recommends the use of creative.js because we regularly add
77
77
features and fix bugs, publishers may choose to hardcode the functionality
78
78
into their ad server creatives.
79
79
80
+
<aname="alt-dyn"></a>
81
+
82
+
### Prebid.js dynamic creatives
83
+
84
+
If you only need to display creatives rendered by Prebid.js (as opposed platforms like AMP or mobile SDKs),
85
+
you can avoid loading the PUC script - and the performance cost that entails - but still keep some of its advantages, such as regular updates,
86
+
by using [Prebid.js dynamic creatives](/adops/js-dynamic-creative.html).
87
+
80
88
<aname="alt-iframes"></a>
81
89
82
90
### Alternate methods for Banner and Outstream Video iframes
@@ -97,9 +105,10 @@ If you only ever need to display non-safeframed banner and outstream-video creat
97
105
If safeframe support is required, some options are:
98
106
99
107
1. Copy the contents of `https://cdn.jsdelivr.net/npm/prebid-universal-creative@latest/dist/creative.js` into each ad server creative.
100
-
1. Copy the example at [github.com/prebid/Prebid.js/blob/master/integrationExamples/gpt/x-domain/creative.html](https://github.com/prebid/Prebid.js/blob/master/integrationExamples/gpt/x-domain/creative.html) into each ad server creative. This is basically just part of the PUC that's been isolated to be standalone.
0 commit comments