ads.txt File

The ads.txt file is a simple, secure method for content publishers to declare who is authorized to sell their ad inventory. Ad Manager promotes the use of the ads.txt file as an industry standard way for advertisers (especially large advertisers) to validate that networks they work with are legitimate.

The ads.txt file includes one line of text for each entity authorized to sell inventory on that domain. Each line includes:

System Domain This is the domain name of the system running the ads on the site, such as google.com or blueadexchange.com  (Note: The domain does not include the ‘http:www’ part of the URL)
Publisher ID or Account Number The account number on the system that is being used to sell ads
DIRECT or RESELLER DIRECT indicates that the publisher who owns the domain directly controls the account.

RESELLER indicates that the publisher has authorized another entity to control the account indicated in field #2 to sell inventory on their site

The exact content of your ads.txt file will depend on how you sell your backfill inventory.

You sell all of your inventory and do not use adsense or any other network for backfill

If you are not using any network for backfill, you do not need to include an ads.txt file on your site.

 

You sell part of your inventory and use AdSense, Ad Exchange or some other vendor for backfill

If you use AdSense for backfill, you can create and add the ads.txt file to  your site.

Your file will include a file that looks like this: gooogle.com, pub-0000000000000000, DIRECT,

In order to proceed, you will need to gather your publisher account numbers.

If you use third parties for programatic backfill, you should request they send you a txt file that includes all of the resellers in their network.

Each line in the file should include the domain of the reseller, the account number of the reseller, and text designation RESELLER

To find your AdSense account number:

  1. Log in to AdSense
  2. Go to SettingsAccount > Account information
  3. Copy the Publisher ID (Note: This is the id that is formatted: pub-0000000000000000)

To find your Ad Exchange account number(s):

  1. Log in to DFP
  2. Go to Admin> Global Settings > Linked Accounts
  3. Copy the Publisher ID of each Ad Exchange (Note: This is the ID that is formatted: pub-0000000000000000)

Note: You must also indicate if you own the Ad Exchange account or if another party owns the account.

The following would be an example for a site that has their own AdSense and Ad Exchange account as well as another party’s Ad Exchange:
google.com, pub-0000000000000000, DIRECT
google.com, pub-0000000000000000, DIRECT
google.com, pub-0000000000000000, RESELLER

 

To add the ads.txt file to the site

Navigate to Settings > Ads.txt and add your file, save update.