ads.txt
ads.txt is a method for protecting advertisers from scammers and earning them more revenue from ads on a website.
It was developed by the Interactive Advertising Bureau (IAB). Here, ADS stands for Authorized Digital Sellers. In the ads.txt file, developers list approved sellers who can send requests to advertisers and sell the website's media kits.
This protocol:
- Lets advertisers know who's allowed to buy and sell certain media kits in their apps and who isn't.
- Protects the user from poor media kits and domain spoofing, which is a type of fraud that lets you sell low-quality traffic while masking it as high-quality traffic.
How it works
When purchasing an app's media kit, the DSP checks which advertising sources are authorized to sell it. To do this, it scans the ads.txt file on the developer's website. The DSP will only accept requests from the advertising sources listed in the file and authorized by the app developer.
Note
If you own multiple domains, be sure to add an ads.txt file to each domain.
To access the ads.txt file, you need to add ads.txt
to your domain name in your browser's address bar (such as example.com/ads.txt
) and press Enter.
This lets the advertiser check whether the platform selling an app's mediakit is on the authorized seller list. If the platform is not on the list, it might be selling poor-quality mediakits.
Advantages of publishing ads.txt
-
It lets you boost your media kit's monetization. Publishing your official seller list proves that your media kit is authentic. Major agencies are more likely to purchase an app's media kit through DSPs that verify authorized advertising sources.
-
This prevents fraud and increases confidence in programmatic purchases: the ads.txt file only lists authorized sellers, which means you protect your domain from scammers and avoid the risk of fake impressions.
By not placing ads.txt:
- DSPs may restrict the purchase of ads in your app.
- You'll lose access to the advertising budgets of major brands and agencies.
- It's more likely that ads intended for you will be served on the platforms of unauthorized sellers.
This may reduce ad revenue.
How to add Yandex and its partners to the authorized sellers of a website's media kit
Step 1. Get the lines for the file from all advertising networks
Each advertising network will provide a code snippet that needs to be added. Contact the advertising network and ask them to send the lines for your ads.txt file.
Note
In the Yandex Advertising Network, an individual code snippet can be obtained in the interface. To download the file with the necessary lines, go to Settings → General and click ads.txt.
Line structure
-
The line contains the domain of the advertising platform, the partner ID, and the type of relationships with the seller.
Example:
example.com, 1234, DIRECT
.The types of relationships with the seller can be:
- DIRECT: Advertising networks with which you cooperate directly.
- RESELLER: Partners that use third-party intermediaries to sell media kits.
We don't recommend adding information about companies you don't work with to the code.
Step 2. Create a file
Open any text editor (such as Notepad), list the lines from all advertising networks, and save the file as ads.txt.
Step 3. Upload the file
Add the ads.txt file to the root directory of the developer's website. A root directory is the folder that follows the top-level domain (such as example.com/ads.txt
).
Note
The file must comply with the IAB Tech Lab ads.txt specification. If you own multiple domains, add the ads.txt file to each of them.
To check whether the file was uploaded correctly, add ads.txt
to the website domain name in your browser's address bar (such as example.com/ads.txt
) and press Enter.
Step 4. Update the file regularly
Advertising network partners may change. Update the contents of the ads.txt file at least once a month so that new authorized sellers can sell your media kits.