Focusing on Google AdWords, for mobile devices, it is possible to distribute advertisements by OS, device model, and network. However, for desktop terminals, surprisingly, it is not possible to distribute advertisements in finer divisions than that.
Rather than allowing AdWords display ads to be targeted by device model or mobile operator, I would like to be able to target by desktop device OS first.
However, with remarketing ads, by skillfully using custom parameters (labels), it is possible to set targeting not only by OS but also by browser.
The usage is limited, but the following is likely to be considered.
- Cases promoting Mac software and accessories (such as power connectors)
- A case of promoting Windows-only software
- Cases where you want to approach designers and web engineers (designers and web engineers tend to prefer Mac over Windows)
Also, by using RLSA (remarketing list for search ads) to control the strength of bids, you can control bids not only for display ads but also for search ads.
Remarketing by Browser/OS in Google AdWords
Using Google Analytics Remarketing Lists
In fact, with the default function of Google AdWords alone, remarketing by browser or OS is not possible. However, it is possible to distribute remarketing.
It’s easy to do, and you can do it by selecting “Property > Remarketing > User List” from Google Analytics’ “Analytics Settings” and specifying the browser and operating system in “New User List > Create New”.
Use custom parameters for remarketing tags
With Google AdWords, you can customize the acquired remarketing and set custom parameters.By using custom parameters, you can combine with your company’s CRM database, or acquire various things that can be acquired via JavaScript or server-side programs. This time, we will use this custom parameter to link browser information and OS information.
When not to use Google Tag Manager
The remarketing tags that can usually be obtained are,
<!-- リマーケティング タグの Google コード -->
<!--------------------------------------------------
リマーケティング タグは、個人を特定できる情報と関連付けることも、デリケートなカテゴリに属するページに設置することも許可されません。タグの設定方法については、こちらのページをご覧ください。
http://google.com/ads/remarketingsetup
--------------------------------------------------->
<script type="text/javascript">
/* <![CDATA[ */
var google_conversion_id = XXXXXXXXX;
var google_custom_params = window.google_tag_params;
var google_remarketing_only = true;
/* ]]> */
</script>
<script type="text/javascript" src="//www.googleadservices.com/pagead/conversion.js">
</script>
<noscript>
<div style="display:inline;">
<img height="1" width="1" style="border-style:none;" alt="" src="//googleads.g.doubleclick.net/pagead/viewthroughconversion/XXXXXXXXX/?value=0&guid=ON&script=0"/>
</div>
</noscript>
It has the form of
var google_custom_params = window.google_tag_params;
is the part where the custom parameter is set. By writing the code below above this tag, you can set the OS and browser information in the custom parameter. The OS name and browser information are set based on the OS information, browser information, and application information in the user agent.When a new browser or new OS comes out, it may be necessary to modify the code.
(function () {
window.google_tag_params = window.google_tag_params || {};
var userAgent = window.navigator.userAgent.toLowerCase();
var appVersion = window.navigator.appVersion.toLowerCase();
// オペレーティング・システムの設定
if (userAgent.indexOf('win') > 0) {
window.google_tag_params['OperatingSystem'] = 'Windows';
} else if (userAgent.indexOf('iphone') > 0) {
window.google_tag_params['OperatingSystem'] = 'iOS';
} else if (userAgent.indexOf('ipad') > 0) {
window.google_tag_params['OperatingSystem'] = 'iOS';
} else if (userAgent.indexOf('mac') > 0) {
window.google_tag_params['OperatingSystem'] = 'Macintosh';
} else if (userAgent.indexOf('android') > 0) {
window.google_tag_params['OperatingSystem'] = 'Android';
} else {
window.google_tag_params['OperatingSystem'] = 'Other';
}
// ブラウザ情報の設定
if (userAgent.indexOf('msie') > 0) {
if (appVersion.indexOf("msie 6.") > 0) {
window.google_tag_params['Browser'] = 'Internet Explorer 6';
} else if (appVersion.indexOf('msie 7.') > 0) {
window.google_tag_params['Browser'] = 'Internet Explorer 7';
} else if (appVersion.indexOf('msie 8.') > 0) {
window.google_tag_params['Browser'] = 'Internet Explorer 8';
} else if (appVersion.indexOf('msie 9.') > 0) {
window.google_tag_params['Browser'] = 'Internet Explorer 9';
} else if (appVersion.indexOf('msie 10.') > 0) {
window.google_tag_params['Browser'] = 'Internet Explorer 10';
} else {
window.google_tag_params['Browser'] = 'Internet Explorer';
}
} else if (userAgent.indexOf('trident/7') > 0) {
window.google_tag_params['Browser'] = 'Internet Explorer 11';
} else if (userAgent.indexOf('chrome') > 0) {
window.google_tag_params['Browser'] = 'Chrome';
} else if (userAgent.indexOf('safari') > 0) {
window.google_tag_params['Browser'] = 'Safari';
} else if (userAgent.indexOf('opera') > 0) {
window.google_tag_params['Browser'] = 'Opera';
} else if (userAgent.indexOf('firefox') > 0) {
window.google_tag_params['Browser'] = 'Firefox';
} else {
window.google_tag_params['Browser'] = 'Unknown';
}
})();
Summarizing the above, the final tag to be installed is as follows (replace the google conversion id with your own ID and install it on your site).
<!-- リマーケティング タグの Google コード -->
<!--------------------------------------------------
リマーケティング タグは、個人を特定できる情報と関連付けることも、デリケートなカテゴリに属するページに設置することも許可されません。タグの設定方法については、こちらのページをご覧ください。
http://google.com/ads/remarketingsetup
--------------------------------------------------->
<script type="text/javascript">
/* <![CDATA[ */
(function () {
window.google_tag_params = window.google_tag_params || {};
var userAgent = window.navigator.userAgent.toLowerCase();
var appVersion = window.navigator.appVersion.toLowerCase();
// オペレーティング・システムの設定
if (userAgent.indexOf('win') > 0) {
window.google_tag_params['OperatingSystem'] = 'Windows';
} else if (userAgent.indexOf('iphone') > 0) {
window.google_tag_params['OperatingSystem'] = 'iOS';
} else if (userAgent.indexOf('ipad') > 0) {
window.google_tag_params['OperatingSystem'] = 'iOS';
} else if (userAgent.indexOf('mac') > 0) {
window.google_tag_params['OperatingSystem'] = 'Macintosh';
} else if (userAgent.indexOf('android') > 0) {
window.google_tag_params['OperatingSystem'] = 'Android';
} else {
window.google_tag_params['OperatingSystem'] = 'Other';
}
// ブラウザ情報の設定
if (userAgent.indexOf('msie') > 0) {
if (appVersion.indexOf("msie 6.") > 0) {
window.google_tag_params['Browser'] = 'Internet Explorer 6';
} else if (appVersion.indexOf('msie 7.') > 0) {
window.google_tag_params['Browser'] = 'Internet Explorer 7';
} else if (appVersion.indexOf('msie 8.') > 0) {
window.google_tag_params['Browser'] = 'Internet Explorer 8';
} else if (appVersion.indexOf('msie 9.') > 0) {
window.google_tag_params['Browser'] = 'Internet Explorer 9';
} else if (appVersion.indexOf('msie 10.') > 0) {
window.google_tag_params['Browser'] = 'Internet Explorer 10';
} else {
window.google_tag_params['Browser'] = 'Internet Explorer';
}
} else if (userAgent.indexOf('trident/7') > 0) {
window.google_tag_params['Browser'] = 'Internet Explorer 11';
} else if (userAgent.indexOf('chrome') > 0) {
window.google_tag_params['Browser'] = 'Chrome';
} else if (userAgent.indexOf('safari') > 0) {
window.google_tag_params['Browser'] = 'Safari';
} else if (userAgent.indexOf('opera') > 0) {
window.google_tag_params['Browser'] = 'Opera';
} else if (userAgent.indexOf('firefox') > 0) {
window.google_tag_params['Browser'] = 'Firefox';
} else {
window.google_tag_params['Browser'] = 'Unknown';
}
})();
var google_conversion_id = XXXXXXXXX;
var google_custom_params = window.google_tag_params;
var google_remarketing_only = true;
/* ]]> */
</script>
<script type="text/javascript" src="//www.googleadservices.com/pagead/conversion.js">
</script>
<noscript>
<div style="display:inline;">
<img height="1" width="1" style="border-style:none;" alt="" src="//googleads.g.doubleclick.net/pagead/viewthroughconversion/XXXXXXXXX/?value=0&guid=ON&script=0"/>
</div>
</noscript>
When using Google Tag Manager
If you’re using Google Tag Manager, you can do this by implementing two custom JavaScript variables and placing them in custom parameters in your remarketing tag.
Describe the two variables to be added.
Operating System
function () {
try {
var userAgent = navigator.userAgent.toLowerCase();
if (userAgent.indexOf('win') > 0) {
return 'Windows';
} else if (userAgent.indexOf('iphone') > 0) {
return 'iOS';
} else if (userAgent.indexOf('ipad') > 0) {
return 'iOS';
} else if (userAgent.indexOf('mac') > 0) {
return 'Macintosh';
} else if (userAgent.indexOf('android') > 0) {
return 'Android';
} else {
return 'Other';
}
} catch (ex) {
return 'Unknown';
}
}
Browser
function () {
try {
var userAgent = window.navigator.userAgent.toLowerCase();
var appVersion = window.navigator.appVersion.toLowerCase();
var name = 'Unknown';
if (userAgent.indexOf("msie") > 0) {
if (appVersion.indexOf("msie 6.") > 0) {
name = 'Internet Explorer 6';
} else if (appVersion.indexOf("msie 7.") > 0) {
name = 'Internet Explorer 7';
} else if (appVersion.indexOf("msie 8.") > 0) {
name = 'Internet Explorer 8';
} else if (appVersion.indexOf("msie 9.") > 0) {
name = 'Internet Explorer 9';
} else if (appVersion.indexOf("msie 10.") > 0) {
name = 'Internet Explorer 10';
} else {
name = 'Internet Explorer';
}
} else if(userAgent.indexOf('trident/7') > 0) {
name = 'Internet Explorer 11';
} else if (userAgent.indexOf('chrome') > 0) {
name = 'Chrome';
} else if (userAgent.indexOf('safari') > 0) {
name = 'Safari';
} else if (userAgent.indexOf('opera') > 0) {
name = 'Opera';
} else if (userAgent.indexOf('firefox') > 0) {
name = 'Firefox';
}
return name;
} catch (ex) {
return 'Unknown';
}
}
Next, edit the AdWords remarketing tag from the list of tags. Select “Specify manually” in the “Custom parameters” field and add custom parameters.
Key | value |
---|---|
Operating System | {{Operating System}} |
Browser | {{Browser}} |
Then, check the operation of the tag and if there are no problems, publish the tag and you are done.
How to set up the list
Select “New remarketing list” from the AdWords user list. The list specified here can be specified not only based on URL, but also based on the custom parameters added earlier. ” is equal to “Macintosh” to create a list of Mac users only.
Remarketing by Browser/OS on Yahoo Display Network
In the Yahoo Display Network, it is possible to perform remarketing by browser or OS in a similar way.
- In the case of Yahoo, it is called “Label” instead of Custom Parameter.
- Only one value can be specified for the label
You may be in trouble if you say that only one value can be specified for the second value, but you can separate multiple values with commas or colons (, 🙂 in that single string. It is also possible to set the value of . Also, in order to ensure that the value can be obtained when generating the list, it is a good idea to put delimiters at the beginning and end of the entire string.
:Windows:Chrome:
When you create a target list for Chrome, you can create it with the condition that the label includes “:Chrome:”.
When not to use Google Tag Manager
the default tag is
<script type="text/javascript" language="javascript">
/* <![CDATA[ */
var yahoo_retargeting_id = 'XXXXXXXXXX';
var yahoo_retargeting_label = '';
/* ]]> */
</script>
<script type="text/javascript" language="javascript" src="//b92.yahoo.co.jp/js/s_retargeting.js"></script>
The OS and browser information are embedded in the “yahoo retargeting label” part of this. The embedded code is almost the same as the Google AdWords version, so only the final tracking code is described. .
<script type="text/javascript" language="javascript">
/* <![CDATA[ */
var labels = (function () {
var ydn_labels = [];
var userAgent = window.navigator.userAgent.toLowerCase();
var appVersion = window.navigator.appVersion.toLowerCase();
// オペレーティング・システムの設定
if (userAgent.indexOf('win') > 0) {
ydn_labels.push('Windows');
} else if (userAgent.indexOf('iphone') > 0) {
ydn_labels.push('iOS');
} else if (userAgent.indexOf('ipad') > 0) {
ydn_labels.push('iOS');
} else if (userAgent.indexOf('mac') > 0) {
ydn_labels.push('Macintosh');
} else if (userAgent.indexOf('android') > 0) {
ydn_labels.push('Android');
} else {
ydn_labels.push('Other');
}
// ブラウザ情報の設定
if (userAgent.indexOf('msie') > 0) {
if (appVersion.indexOf("msie 6.") > 0) {
ydn_labels.push('Internet Explorer 6');
} else if (appVersion.indexOf('msie 7.') > 0) {
ydn_labels.push('Internet Explorer 7');
} else if (appVersion.indexOf('msie 8.') > 0) {
ydn_labels.push('Internet Explorer 8');
} else if (appVersion.indexOf('msie 9.') > 0) {
ydn_labels.push('Internet Explorer 9');
} else if (appVersion.indexOf('msie 10.') > 0) {
ydn_labels.push('Internet Explorer 10');
} else {
ydn_labels.push('Internet Explorer');
}
} else if (userAgent.indexOf('trident/7') > 0) {
ydn_labels.push('Internet Explorer 11');
} else if (userAgent.indexOf('chrome') > 0) {
ydn_labels.push('Chrome');
} else if (userAgent.indexOf('safari') > 0) {
ydn_labels.push('Safari');
} else if (userAgent.indexOf('opera') > 0) {
ydn_labels.push('Opera');
} else if (userAgent.indexOf('firefox') > 0) {
ydn_labels.push('Firefox');
} else {
ydn_labels.push('Unknown');
}
return ':' + ydn_labels.join(':') + ':';
})();
var yahoo_retargeting_id = 'XXXXXXXXXX';
var yahoo_retargeting_label = labels;
/* ]]> */
</script>
<script type="text/javascript" language="javascript" src="//b92.yahoo.co.jp/js/s_retargeting.js"></script>
When using Google Tag Manager
In the case of YDN, even if you use Google Tag Manager, you have no choice but to define the tag as custom HTML, so it is possible to use the above tag as it is in cases where Google Tag Manager is not used. I think that two variables are created when the same thing is done in the tag, so if you use them to create a custom HTML tag, the tag will be concise. If you change it as follows, you can set the OS information and browser information to the label.
<script type="text/javascript" language="javascript">
/* <![CDATA[ */
var yahoo_retargeting_id = 'XXXXXXXXXX';
var yahoo_retargeting_label = ':{{OperatingSystem}}:{{Browser}}:';
/* ]]> */
</script>
<script type="text/javascript" language="javascript" src="//b92.yahoo.co.jp/js/s_retargeting.js"></script>
summary
In both Google AdWords and Yahoo Promotional Ads, the default function does not allow ads to be displayed separately for each OS or browser on desktop terminals. By adding this, it becomes possible to display advertisements by OS or by browser.
If you have an account that you manage and you can expect performance improvement by displaying advertisements by OS or browser, please try it.