2

When setting up a new custom channel in Google AdSense, you can associate it with any ad units from the UI, meaning each ad unit can be associated with more than one custom channel.

AdSense also allows you to provide a data-ad-channel attribute on the ad unit code itself. Here's the example from the documentation:

<script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=[redacted]" crossorigin="anonymous"></script>
<!-- signed_in_ad_unit -->
<ins class="adsbygoogle"
     style="display:block"
     data-ad-client="ca-pub-1234"
     data-ad-slot="1234"
     data-ad-format="auto"
     data-ad-channel="1234"
     ^^^^^^^^^^^^^^^^^^^^^^
     data-full-width-responsive="true"></ins>
<script>
     (adsbygoogle = window.adsbygoogle || []).push({});
</script>

The documentation suggests you can add multiple channels to an add unit: If you add an ad unit to more than one custom channel or assign more than one custom channel to an ad unit.

But how can you do this using the data-ad-channel?

1 Answer 1

2

Although it's not documented, you can ad multiple ad channels to a single ad unit by separating with channel IDs with the + symbol:

data-ad-channel="1234+5678+9012"

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.