DoubleClick Natural Search

Deploy the natural search tag to your landing pages

Customer support will send the DoubleClick Natural Search tracking tag to you. Have your webmaster post this tag within the body of each page that might receive traffic from a search engine visit.

Note the following:

  • To ensure accurate tracking:

    • The tag should be posted on every page that might receive traffic from a search engine visit, even vanity pages.

    • Post the tag close to the top of each page and within the HTML body tag.

    • The tag must be called upon every page load.

  • If you're adding the tag to a secured page (that is, a page that's accessible only via the https protocol), change the protocol in the natural search tag to https.

    See an example

    For example, DS support gives you a tag that looks like this:
    <script type="text/javascript">
    // DoubleClick DART Natural Search Tracking Code
    if(document.referrer){
     var ord=Math.random()*1000000000000;
     document.write('<SCRIPT language="JavaScript1.1"
     SRC="http://ad.doubleclick.net/adj/Nxxxx.xxxxxx.NSO.CODESRV/
     Bxxxxxxx;dcadv=xxxxxxx;sz=1x2;ord=' + ord + '?"><\/SCRIPT>'); }
    </script>

    When you add the tag to secured pages, change the SRC attribute to start with https:
    <script type="text/javascript">
    // DoubleClick DART Natural Search Tracking Code
    if(document.referrer){
     var ord=Math.random()*1000000000000;
     document.write('<SCRIPT language="JavaScript1.1"
     SRC="https://ad.doubleclick.net/adj/Nxxxx.xxxxxx.NSO.CODESRV/
     Bxxxxxxx;dcadv=xxxxxxx;sz=1x2;ord=' + ord + '?"><\/SCRIPT>'); }
    </script>

  • The natural search tag already contains the appropriate JavaScript wrapper to perform cache-busting.

For questions regarding privacy, refer to the DoubleClick Privacy page or contact customer support.

Use Google Tag Manager to deploy the natural search tag

Google Tag Manager makes it easy to manage tags from multiple Google sources, such as Google Analytics, Floodlight, etc. If you’re using Google Tag Manager for your site, follow these steps to deploy the DoubleClick Natural Search tag:

  1. Go to google.com/tagmanager, sign in, and access your site’s container.

  2. Create a rule:

    1. Click the New button and select Rule.

    2. Enter a name, for example Natural search rule.

    3. In the first line under Conditions, make sure the first list is set to {{url}}. In the next list, select matches RegEx, and in the text field enter . *

    4. In the second line, select {{referrer}} in the first list, matches RegEx in the second list, and in the text field enter . +

    5. Click Save.

  3. Create a tag:

    1. Click the New button and select Tag.

    2. Enter a name, for example Natural search tag.

    3. From the Tag Type list, select Custom HTML Tag.

    4. Paste the Natural Search tag from DS customer support into the HTML field.

    5. Select the Support document.write checkbox.

    6. Next to Firing Rules, which appears near the top of the page, click +Add.

    7. Select the rule you created in the previous step and click Save.

    8. Click Save to save your new tag.

  4. Follow the standard publishing process for Google Tag Manager:

    1. Create a container version.

    2. Preview and debug the version.

    3. Publish the new version.

Test the deployment from Google Tag Manager

If you used Google Tag Manager to deploy your tag, do the followint to test the deployment:

  1. In a Chrome web browser, visit the Chrome Web Store and install the Google Tag Assistant.

  2. Visit your site through a natural search result.

  3. Use the Tag Assistant to check that the Natural Search tag has fired.

  4. Visit another page on your site. (Don’t click a search result this time.)

  5. Use the Tag Assistant to check that the Natural Search tag did not fire.

Webmaster FAQs

Does this tag replace DART Floodlight tags?
The DoubleClick Natural Search tag is not itself a Floodlight tag. It is the tag responsible for tracking arrivals or visits from search engines and therefore is the essential part in DoubleClick Natural Search tracking.

 

Where on the page should the tag be posted?
The tag must be called every time the page loads. Posting the tag close to the top of the page within the HTML body tags is preferred. This will result in the most accurate tracking.

 

Can I use server-side include or some other language like Perl for the cache busting?
Yes, the webmaster may use whatever method as long as the tag contains a sufficiently random dynamic string. The JavaScript wrapper provided by DoubleClick is meant to facilitate implementation and is only a suggestion. Client-side cache busting is preferred to server side.

 

How long do I leave the tag up on the site?
The tag must remain in place for DoubleClick Natural Search tracking to occur. The tag should not be posted, removed, and re-posted repeatedly. The tag should not be conditionally written to the page.

 

The tag is negatively affecting my page load time. Can I take it down?
The tag is very small, about 2.4 kb, and it's designed to have a minimal impact on page load. DoubleClick Natural Search tracking cannot occur without the tag in place.

 

I don’t want a DoubleClick ad tag on my homepage. What can I do?
Search engines most often direct users to the homepage. Therefore, the homepage may be the most important location for the tag to be posted. If the tag is not present, DoubleClick Natural Search tracking cannot occur.

 

I have dynamically generated pages. Where should I post the tag?
The tag needs to render along with page content and load with each page request.

 

On what other pages should I post the tag?
Post the tag to any page that might be the landing page for a natural search visit. This includes vanity pages, temporary pages, or any associated pages that need to be tracked. For example, some clients maintain an About Us page.

 

On what pages should I include the exclusion parameter?
If you are running Paid Search campaigns, use this exclusion parameter on every page that the tag is used. If this is not done, natural search visits will not be counted. Implement the exclusion parameter like any other query string value. If no query string exists, add a new one. If your server does not support arbitrary exclusion parameters in the page URL, consult the implementation specialist for an alternate method.