A Custom Choice message allows you to offer ad blocker users the choice to either allow ads on your site or select a custom option that you implement. For example, you can offer ad blocker users the option to allow ads on your site or buy a subscription to your site.
Complete the following steps to implement a Custom Choice option in an ad blocking recovery message:
- Implement
googlefc.controlledMessagingFunction
of the Google Privacy & Messaging API. You must implement thegooglefc.controlledMessagingFunction
function of the Google Privacy & Messaging API before publishing your custom choice message. This function is required, and helps ensure that users who have complied with the terms of the custom choice do not see the message again on future visits. Place the function between the<head>
and</head>
tags in your site’s HTML code. - Select the "Add custom solution" option. When you create an ad blocking recovery message, select the Add custom solution option. This will allow you to offer users an alternative solution of your choosing (for example, buying a subscription to your site).
- Set up your ad blocking recovery message. Complete the following steps when editing your ad blocking recovery message:
- (Optional) Edit the button text for your custom choice, if necessary.
- In the Custom URL field, enter the URL to which the button should link. For example, you might enter the URL of your subscription sign-up page.
- (Optional) Edit the "Already a subscriber" footer text, if necessary. This footer link is used for users who believe they have already complied with the custom choice.
- In the Footer URL field, enter a URL for the footer. For example, the URL might take users to a page that verifies that they are already a subscriber to your site.