A macro is a change to a string of text that makes up third-party ad tags that is made in order to allow publisher and advertiser to accurately perform certain functions, such as counting impressions and clicks. Inserting macros into third-party tags involves removing a certain string of text from the “raw” tags and replacing it with a standardized code. For example, a cachebuster macro can be inserted by replacing a line of code with: %%CACHEBUSTER%%.
The most commonly-implemented macros include:
- Cachebuster Macros. This macro is inserted to force the platform to make a new call to the ad server each time an impression is served (instead of serving up a cached image). This is perhaps the most important macro; it helps to avoid counting discrepancies.
- Click Macros. This macro lets publishers track the number of times a third-party ad is clicked. This is valuable information if you are monitoring campaign performance; it will allow you to spot under-performing units and be prepared to optimize.
These are the most important macros to insert into ad tags. There are a number of other macros available if needed. The adjacent table contains a link to a more detailed explanation of all macros from DFP.
Many ad servers will automatically insert macros into third-party tags from known platforms. For example, DFP will show the following message after a publisher uploads third-party tags:
If the ad server platform does not recognize the tags as being generated by a known platform, publishers will need to insert the macros themselves. Below is an example of the message that appears in DFP:
It is generally possible to upload and save ad creatives without inserting macros. However, this is not recommended; it will more often than not cause headaches down the road (especially if there are discrepancies in billing).
Many third-party ad tag providers have online manuals that help advertisers insert macros “manually” if needed.
Macro is a variable that expands automatically into a set of instructions to perform a particular task and only works on that level where it is defined, Macros can be used for:
- Impression tracking pixels
- Click tracking pixels
- Tracking scripts
- Landing page URL
- Third party banners
What does macro mean in display advertising?
A macro is a change to a string of text that makes up third-party ad tags that are made in order to allow publishers and advertisers to accurately perform certain functions, such as counting impressions and clicks.
How does macro work?
This macro only works for approved suggested ad units. If a suggested ad unit is at the third level, this macro only expands to the second-level ad unit when used in the creative snippet. Once the suggested ad unit is approved, the macro expands to the third ad unit level in the creative snippet.
How to implement macro?
Many ad servers will automatically insert macros into third-party tags from known platforms. If the ad server platform does not recognize the tags as being generated by a known platform, publishers will need to insert the macros themselves