ConnectAd Chronicles

Tutorial

ads.txt guide for publishers looking to thrive

As much as we love digital advertising, we all have to admit one thing: In its current form, it is often neither safe from cybercriminal attacks nor can it be said in good conscience that it is particularly sustainable. And that has to change. The shift to a more secure and sustainable digital landscape is not only being discussed all the time – it is already happening right now.

And at ConnectAd we strongly believe that those who adapt and embrace this change now, will thrive. But what does all this have to do with ads.txt? In this article we’ll tell you!

'Bad' digital ad spending harms your business and the environment 

The online advertising industry has long grappled with widespread ad fraud, with estimates suggesting that it cost advertisers around $81 billion in 2022 alone. This rampant fraud inflates the number of ad impressions and clicks, leading to significant financial losses. Additionally, the inefficiencies and wasted energy from these fraudulent activities contribute to carbon emissions. If, on the other hand, online campaigns are made more transparent and optimized in terms of security, this also contributes to greater sustainability.

What ads.txt is and why it helps you to solve this problem like a pro 

Ads.txt is a simple text file that the Interactive Advertising Bureau (IAB) introduced in 2017 allowing publishers to publicly declare the companies authorized to sell their advertising inventory (and buyers to verify the sellers authorized by publishers). For quite some time now ads.txt increases transparency, helps to combat fraud in the online advertising ecosystem and reduces the ecological footprint of all those involved. It is therefore nothing new that providers with 50+ads.txt reseller lines are being scrutinized. Because: This is not a unique demand, but a re-selling construct. Publishers should therefore always give preference to partners with few ads.txt lines (around 10 lines should be considered healthy) when selecting demand partners. 30+ lines are no longer up to date and should definitely be questioned!

All well and good … but how does ads.txt actually work?

Publishers add the ads.txt file to their websites to verify domain ownership. Specifically, this means that they place a, publicly accessible via the URL, text file named “ads.txt” at the root of their domain. This file lists the domain names of authorized sellers, their unique IDs, the type of relationship (direct or reseller), and sometimes a certification ID from the authority. Advertisers can then check the ads.txt file to confirm the legitimacy of a publisher’s ad inventory before bidding. If the publisher ID matches the ads.txt file, the advertiser can trust the inventory. If not, they may opt not to bid, ensuring only legitimate ad spaces are purchased. This helps avoid fraudulent transactions and ensures transparency.

… and how does one create an ads.txt? 

Creating an ads.txt is easy and it only takes a few steps to upload it to a website as it is saved as a text file and uploaded into the root domain with all the authorized sellers. But let’s proceed step by step!

Step 1: Open a text file

To start composing your file you can use any basic text editor such as Notepad,TextEdit or even Microsoft Word.
Important: The ads.txt files must be formatted with commas between all the lines.

Step 2: List the authorized sellers

Write down the domain names of ad sellers authorized to sell your ad inventory. For example: google.com

Step 3: Add the identifiers

For each seller you can now include additional details that facilitate identification and validation. Each line in the Ads.txt file should contain the domain name, the publisher/ account ID, the type of relationship (direct or reseller) and the certification authority ID. For example: connectad.io,1000,DIRECT,85ac85a30c93b3e5
Good to know: While IDs and certifications are not mandatory, they are recommended to enhance traceability and security.

Step 4: Save the file

Once your list is complete, save the file as “ads.txt” and make sure to place it at the root of your website. This is where ad buyers will expect to find it, for example at publisher.com/ads.txt

Step 5: Publish your file on your site

Finally you can set up ads.txt files through WordPress, Google AdSense Google Ad Manager. This will allow ad buyers to easily verify with whom they can contract securely.

Always keep in mind:Updating your ads.txt is crucial


The cleanliness of the ads.txt file has been neglected by the entire online advertising market for quite a long time. But today it’s different – the trend is changing as more and more publishers and DSPs are streamlining the often overloaded ads.txt file by adding new sellers or removing those who are no longer authorized. They finally came to realization that it is necessary to keep the ads.txt up to date on behalf of transparency and fraud prevention, increased buyer confidence and optimization of ad revenue.

How to keep track with your ads.txt in 5 simple steps


It's a good thing that it's not difficult at all to keep your ads.txt up to date. Just follow these steps:

Step 1: Identify your advertising partners

Review your current advertising partners once in a while as they are the ones who help you monetize your site by displaying ads. Note their domain names.

Step 2: Verify the information

Always make sure you have the correct information about each of your partners. You need their domain name and their seller ID.

Step 3: Open your ads.txt file

You can open your site’s ads.txt file with a simple text editor

Step 4: Add new lines

Add a new line to your ads.txt file for each partner.

Step 5: Remove outdated entries

If advertising partners are no longer active or if you stopped working with them, remove their information from your ads.txt file. Like this the file remains up-to-date and free from any unnecessary references, improving its accuracy and reliability.

Tip: Another possibility to easily validate ads.txt lines are tools like the ads.txt Guru Validator or sellers.guide by Primis.

We hope that this article was able to demystify the concept of ads.txt a bit and that you can understand why it is nowadays so important to have it and keep it updated! Need any help with that? We’re here for you!

Just reach out!