Features | Pricing | Demo | Clients | About

Help Center > Manage Your Account > Ad Targeting using Restrictions

Target ads by placement URL or referring URL

You can show an ad to visitors viewing a certain web page (placement URL) or coming from a certain web page (referring URL). You can block an ad from showing on a specific page or section. URL matching is done with a regular expression. Wildcard is supported for partial matching. For advanced matching, basic knowledge of regular expressions is required.

Example

Your website has 2 main sections: Travel and Music. This is the URL structure:
  • http://example.com/Travel/
  • http://example.com/Travel/Florida.html
  • http://example.com/Travel/California.html
  • http://example.com/Music/
  • http://example.com/Music/Electronica.html
  • http://example.com/Music/Pop.html
You do not want Travel ads to display in the Music section and vice versa. As a solution, you can put a placement URL restriction on the Travel ads to prevent them from showing when the placement URL is one of the Music pages:
  • Sign into your account, follow the menu Ads / All
  • Click on an ad name
  • Click on the Restrictions tab, click on Add
  • Choose the restriction type Placement URL
  • Choose Don't Show mode
  • Type in a path or directory that is unique for that section. In our example it would be http://example.com/Music/*. Wildcard is used to match all pages within the section
  • Save the new restriction and this ad will not be shown to visitors when they are in the Music section
The same instruction applies when you want to target ads by referring URL, which is the page where your visitors come from. Please note that referring information is dependent on the visitor's browser. Some browsers have settings and plugins to block or modify the referring field.

Domain Matching

In order to restrict an ad to only display on certain domains and hostnames, you can use this special format:
DOMAIN(example.com|www.example.com)
In this example, the ad will not show if it is being served on a different site other than the two registered hostnames. Sub-domains are considered as unique hostnames.

Combining Multiple URLs

Instead of creating multiple URL restrictions, which can be time consuming, you can combine multiple URLs that share a similar pattern together. For example:
  1. Don't show to visitors viewing page http://example.com/signup/publisher
  2. Don't show to visitors viewing page http://example.com/signup/advertiser
  3. Don't show to visitors viewing page http://example.com/signup/ad-agency
  4. Don't show to visitors viewing page http://example.com/signup/ad-exchange
Since they share the same domain and path, they can be combined into one URL restriction:
  1. Don't show to visitors viewing page http://example.com/signup/(publisher|advertiser|ad-agency|ad-exchange)

Advanced Matching

Follow these instructions if you want to show this ad only on specific sections. For example: ad AdServer should only display when a visitor is browsing these 3 content sections: Marketing, B2B, or Advertising. A placement URL restriction can be created as follows:
  • By Name: Show to visitors viewing this page *&SectionName=(Marketing|B2B|Advertising)
  • By ID: Show to visitors viewing this page *&SectionID=(222|333|444)

If you would like to show only for any section with a valid numeric ID: *&SectionID=[0-9]+

The "|" means any value between the parentheses. For more technical usage, our serving engine uses regular expression to match the URL with your restriction.

To restrict the end of a string, add "$" to the pattern. Example: "http://example.com/travel$". This will only match the exact/full URL and will not match "http://example.com/traveling" or "http://example.com/travel/". URLs with or without a trailing slash should be redirected to a consistent URL scheme.

Considerations

  • The availability of referring information depends on the browser. Some browser add-on/setting can block or modify referral information from passing onto the request and restrictions based on referring URL will not work properly.
  • Reporting are available per zone and per ad. Reports are not available per URL or per restriction.
  • When generating the serving code, it is recommended to choose the Comprehensive serving code format to ensure the referring and placement URLs are captured properly. If you need an ad serving feature that is only available with a JavaScript ad tag, you might need to add additional JavaScript tracking code to properly capture the referring URL. Please contact us for technical assistance in adding this tracking code.

Example Setup

Other Articles in Ad Targeting using Restrictions

Learn about restrictions such as frequency capping, geotargeting, quota, roadblock, flight date, etc.
Search Help Center
There was a problem with your submission. Please correct the following items:

    Cannot find an answer for your question? Ask our Customer Care team

    Related Articles

    Have questions? Contact Us

    Testimonials

    • You have always been dependable and have been a very valuable asset to our business.

      Trever K
      Road And Travel Magazine

    • Thank you, Thank you, Thank you! You have performed well past the monthly fee I pay AdSpeed.

      Gary C
      2Cooleys Ozark Recreation and Tourism Media