prebid / prebid.github.io

Repo that controls Prebid.org website
http://prebid.org
Apache License 2.0
69 stars 1.19k forks source link

Prebid universal creative renders creatives as size 1x1 in AMP environments instead of the actual creative size #3570

Closed Alexa0100 closed 2 years ago

Alexa0100 commented 2 years ago

I have seen several Publishers using server-side header bidding for AMP and seeing 0% viewability.

After investigation, it looks like these publishers have size overrides set on the Prebid Universal Creative in GAM for traditional banner sizes such as 300x250. However, the creative is rendering on the page as the Universal Creatives' actual size 1x1. This means that banner placements are effectively not viewable.

On AMP pages, I see bids returned with the creative size as 300x250 or similar and the cached creative also return that size. However, the iframe sub-element within the amp-ad element on the page resizes to 1x1 and renders the creative in that size. When I manually resize the iframe element, I see the creative appear.

Reproduction steps:

  1. Set User-Agent to iOS (necessary to see valid calls on the page)
  2. Place the test segment link in your browser: https://secure.adnxs.com/seg?add=23865920
  3. Navigate to: https://www.cnet.com/google-amp/news/spellbound-by-the-sound-of-kinters-33-stereo-amplifier/?apn_test=true&test=true
  4. Filter for network calls to: ib.adnxs.com/prebid/amp
  5. Look for a response from the bidder appnexus
  6. Copy down the tag ID and in the elements tab search for the tag ID and scroll into view
  7. Open the amp-ad elements sub-elements and see the iframe sizes as 1x1
  8. Manually resize the iframe to 300x250 and see the creative display

Video Reproduction:

https://user-images.githubusercontent.com/66432037/153928232-a443a18d-ae28-41e8-9366-6709720499aa.mp4

Universal Creative Set Up in GAM:

Screen Shot 2022-02-14 at 1 32 22 PM
bretg commented 2 years ago

@Alexa0100 - I don't think this issue belongs in the docs repo, but will give it a go. Appreciate the effort you put into reporting this, but I can't get a test bid. What does https://secure.adnxs.com/seg?add=23865920 do? I'm using chrome dev tools in emulation mode, so see an iPhone user agent.

General thoughts:

https://github.com/prebid/prebid-universal-creative/blob/23d1f099be9a0d44fb6da0f6a9548069ff2fea2d/src/renderingManager.js#L203

Alexa0100 commented 2 years ago

Hi @bretg really appreciate you taking this up! You are right this probably doesn't belong in the docs repo, I am happy to move it somewhere else if that is best!

Here is a better screenshot of the AMP creative set up in GAM

Screen Shot 2022-02-24 at 4 40 56 PM

vs the set up of another publisher who is not seeing this viewability problem and has the actual size set to 300x250 rather than 1x1

Screen Shot 2022-02-24 at 4 48 03 PM
Alexa0100 commented 2 years ago

I'll check for the console error as well.

For reproduction of bids, I've noticed it really helps to be off of a VPN. I hope that will work for you!

bretg commented 2 years ago

@Alexa0100 - I notice your 1x1 creative doesn't have the safeframe box checked - please try that. Will try again to repro this issue this afternoon

Alexa0100 commented 2 years ago

When I tried to reproduce today, I noticed that it looks like my line item is still bidding but losing in the ad server

That did allow me to confirm that when the creative comes from Google itself and not from the prebid/amp call the iframe does not resize to 1x1.

Returned GAM Creative iframe when creative comes from Google not prebid call
Alexa0100 commented 2 years ago

Thanks for the tip on the safe frame. This is a client's GAM set up so I don't want to make bulk changes to their creatives without their go-ahead

What I think I should also try next is making a new line item between two current price buckets (checking the safe frame option) and also setting the actual size of the creative to 300x250 rather than 1x1. And then seeing if when I target that exact price point if the iframe respects the returned size

Alexa0100 commented 2 years ago

@bretg would you mind helping me also move this question to the prebid universal creative repo? I was looking for a way to move it, because I think it would be better to have it live in the proper location

bretg commented 2 years ago

Sorry @Alexa0100 - I don't think there's a way to move an issue. It would have to be re-opened. But honestly, it's not like this will get any more attention over there.

Have you gotten a chance to try the safeframe flag? As far as I know, AMP requires safeframes.

I don't see a problem with the PUC code -- it resizes. I haven't been successful in reproducing this problem. But I haven't yet tried going to deselect the safeframe flag in our ad server.

If you still see the issue with the safeframe flag set, I'll put some more time into trying to reproduce the issue. However much I appreciate the nice instructions you placed above, I can't get them to work. What does Step 2 mean? "Place the test segment link in your browser". Does this mean paste the adnxs.com link to set a debug cookie of some kind, then immediately paste the CNET link?

Alexa0100 commented 2 years ago

Hi @bretg !

I previously thought the creatives would automatically serve in a safe frame based on the Google Docs: "For AMP pages, standard HTML creatives are always served into SafeFrame, regardless of your selection. Please make sure your creative code is compatible with SafeFrame."

And because when I first uploaded them, the creative box in GAM said that all new creatives would automatically serve in a safeframe.

But I edited all of the creatives this morning, and I do see it making a difference in the iframe resizing on the page. I'm keeping an eye on reporting data too to validate and will have another update there.

I'm hopeful this is the fix! Thank you !!

Alexa0100 commented 2 years ago

Good morning @bretg, I wanted to let you know that I'm seeing drastic improvements in the viewability rate since making the safe frame change and no more 1x1 resizing on the page! Thanks for your help here, I really appreciate it!

I'm going to pass the advice on to a few other publishers I've seen with the same GAM set up and seeing very limited viewability on AMP. Thanks again!

bretg commented 2 years ago

@Alexa0100 - that's great news. May we close this issue?

Alexa0100 commented 2 years ago

yes, we can go ahead and close the issue. Thanks for all your help here!