Don't Have Time To Read the Entire Guide Now?
We'll email you a downloadable PDF version of the guide and you can read later.
With programmatic advertising came a massive boom in revenue opportunities for digital publishers. But as is the case with any good thing, bad actors wanted to get in on this new revenue source without putting in the work.
Pretty much as soon as programmatic advertising was invented, ad fraud started taking a bite out of both digital advertising revenue and advertisers’ confidence in digital advertising on the whole. The problem grew quickly, to tens of billions of dollars lost to ad fraud every year.
Then, a solution. It’s called ads.txt. From a nascent technology just a few years ago to a stalwart feature of thousands of publishers’ ad tech stacks today, ads.txt has become an essential part of any serious publisher’s digital advertising strategy.
In this guide, we’re going to explore everything publishers need to know about ads.txt, including how it works, how to implement it and how it benefits you. Read on to learn more.
What is Ads.txt?
Let’s start with the thing itself — what is ads.txt, anyway? At its most basic level, it is a text file that contains lines of code. At its most sophisticated level, it is a secure, flexible way for publishers to allow approved companies to sell their digital advertising inventory.
You might assume that the “ads” in ads.txt is referring to advertising, but it’s actually an acronym for Authorized Digital Sellers. It’s a project from the IAB Tech Lab that, shortly after its release, gained widespread adoption and even became a featured part of Google AdSense’s user interface.
Programmatic advertising can happen on a wide variety of channels, and because each of these channels is susceptible to ad fraud in unique ways, ads.txt has grown to include not just websites, but mobile apps and over-the-top (OTT) platforms.
Learn more about Ads.txt for different platforms below:
Ads.txt for Web
Ads.txt started with websites. For web publishers, ads.txt is a text file that the publisher creates and hosts on their site, usually at a top-level URL that looks something like this:
That text file contains information that authorizes particular exchanges and supply-side platforms(SSPs), or sellers, to sell the publisher’s traffic. When buyers are responding to each bid request, they verify that the digital seller is listed in the publisher’s ads.txt file to ensure that the transaction is safe and fraud-free.
A couple of years after ads.txt was created, the IAB Tech Lab saw the need for a similar fraud-prevention solution in the in-app advertising space. Apps may be distributed via relatively secure mobile app stores such as the Google Play app store, the Apple app store, etc. but they are just as vulnerable to ad fraud as websites.
That realization led to the creation of app-ads.txt. It does basically the same thing as ads.txt, but it’s specifically meant for mobile apps. Keep in mind that, while ads.txt and app-ads.txt do essentially the same thing but for different channels, they are separate files that authorize different sets of sellers.
As OTT advertising has grown in tandem with sales of Rokus and similar devices, ad fraud has also grown in this space. Ad tech industry leaders didn’t have to engineer a whole new solution for this problem, though. They already designed app-ads.txt for use in OTT channels.
The Scope of the Problem Ads.txt Tries to Solve
We know the problem ads.txt was designed to solve — ad fraud — exists. But how widespread was this issue? To lead to creating a free technology that gained quick adoption must have been pretty bad.
It certainly was. Right around the time ads.txt was released in 2017, one study found that advertisers were wasting nearly $1.3 million USD in programmatic ad spend per day because of a single domain spoofing scam that caused them to buy inventory on duplicated and fake publisher sites.
Meanwhile, for the industry as a whole, experts predicted that digital advertising fraud would cost more than $100 billion dollars annually by 2023.
Ads.txt isn’t a perfect solution — scammers and fraudsters are constantly finding new ways to game the system — but it prevents a host of ad fraud schemes and injects some much-needed trust into the programmatic ecosystem. Here are a few of the types of programmatic advertising fraud that ads.txt can help prevent:
Domain spoofing is a common scam across a wide variety of digital industries, but in programmatic advertising, it had a particularly devastating effect. Fraudsters would “spoof” publishers’ domains — meaning they would duplicate them — and sell inventory on the spoofed site.
The issue domain spoofing creates is that advertisers believe they are getting inventory on a publisher’s site that gets a certain amount of traffic. A spoofed site may have no traffic or very little, or its traffic may be from bots. In other words, the ad placed on the spoofed site will do nothing for the advertiser in terms of brand awareness or sales. It’s wasted money.
But the fraudster who spoofed the site still gets the check. This is the problem ads.txt was designed to solve. By authorizing only particular sellers on their domains, publishers give inventory buyers a way to verify that they’re really getting what they’re paying for. And the only way to manipulate this ad exchange would be for a hacker to get into the publisher’s site and edit the publisher’s ads.txt file.
Like it or not, programmatic advertising involves a lot of middlemen. On polar opposite ends of the process, you have the publisher and advertisers. But between them, you typically have at least one SSP and one demand-side platform (DSP). Each of those middlemen takes a cut of each programmatic dollar, reducing the revenue of publishers and/or increasing the cost for advertisers.
That may not be ideal for publishers and advertisers, but it’s how it’s supposed to work. Unfortunately, it’s a complicated, sometimes inefficient ecosystem that allows for fraud-prone middlemen to insert themselves into the mix. Here’s what they do: they buy up publishers’ inventory and resell it at a higher price to advertisers.
This is called arbitrage. And while it is a shade less shady than domain spoofing, it’s a significant problem in the digital advertising industry because it causes advertisers to pay too much for inventory, reducing their ability to buy more inventory from publishers and lowering their ROI on ad spend.
While ads.txt was designed to stop domain spoofing, it inadvertently hampered inventory resellers’ ability to insert their DSPs and SSPs into the programmatic pipeline. Overall, this improved the landscape for both publishers and advertisers.
Who Uses Ads.txt?
It didn’t take long for the benefits of ads.txt to become clear to publishers. Ads.txt was released in the spring of 2017, and by September of that year, 16% of publishers had adopted it. Just two months later, in November, 57% of the top 1,000 publishers who sold ads programmatically had ads.txt files on their sites.
That figure has held relatively steady in the past four years, with a greater percentage of top publishers than lower-tier publishers adopting ads.txt. Now, having an ads.txt file is considered common courtesy among high-quality publishers who are in the programmatic space.
History of Ads.txt
Released in May of 2017, ads.txt is relatively new if you place its invention on a timeline of advertising innovations. But in terms of ad tech, half a decade is a lifetime. A lot has changed since day one of ads.txt, but the technology remains an important fixture in a fully optimized digital ad revenue strategy.
Between the advent of programmatic advertising, somewhere around 1994, and 2017, digital ad fraud grew from a whisper to a roar that no amount of newfound digital ad revenue could drown out. Advertisers were losing millions and hemorrhaging their trust in programmatic buying, and publishers were feeling the effects of that lost trust on their bottom lines, too.
That’s when the IAB Tech Lab, an independent and nonprofit arm of the Interactive Advertising Bureau, began working on the solution that would eventually be called ads.txt. IAB Tech Lab is a consortium that includes members on the publisher, advertiser, and pure ad tech sides. The development of ads.txt was nothing less than a historic and monumental effort by advertisers and publishers who shared the common interest of fighting digital ad fraud.
Benefits of Ads.txt for Publishers
The benefits of ads.txt for advertisers are clear — it enables them to purchase digital ad inventory with confidence because they can verify that the seller is legitimate. But what are the benefits of ads.txt for publishers?
At it's highest level, ads.txt provides a little bit of clarity in a very complex ecosystem. The path an ad takes from advertiser to publisher is anything but simple.
Ads.txt provides some assurance to advertisers that their ads are ending up on the publisher websites they are expecting them to, and that those impressions are legitimate.
So, in large part, the benefits on the publisher side are an extension of the confidence ads.txt instills on the advertiser side. Here are a few of the benefits for publishers:
Ads.txt compliance is a benchmark metric for many high-dollar advertisers. If you’re compliant with ads.txt, you can get in the running for those higher-dollar buys.
By participating in the ads.txt system, you strengthen its anti-ad fraud power. Indirectly, a stronger anti-fraud force instills confidence in programmatic advertising on the whole and can lead to more revenue for publishers across the board.
How to Create an Ads.txt File
With benefits like those, it’s no great wonder why so many publishers are eager to get ads.txt on their sites. To do that, you need to create an ads.txt file.
If you’ve ever opened up a blank document in Notepad or TextEdit, you know how to complete the first step. When you’re done writing it, you’ll need to save the file with the .txt file extension.
Remember — your ads.txt file is simply a list of sellers you authorize to sell your inventory. For each seller you want to authorize, you will need to include information in four categories:
- The domain name or name of the seller you want to authorize
- Your unique publisher ID number in the seller’s platform
- The relationship the entity you are authorizing has with your inventory, such as DIRECT for a seller who deals directly with publisher inventory
- An optional TAG ID number from the Trustworthy Accountability Group to note that the ad system you’re authorizing is certified
Each of those pieces of information goes on one line and should be separated by commas. Repeat the process for each additional authorized digital seller on a new line in the text file.
That sums up the process at its most basic, but keep in mind that there are various other capabilities that an experienced developer or ad partner can implement. For example, a dynamic ads.txt file can automatically update with new sellers. You can also add comments and variables to ads.txt files.
Also, various programs and plugins can do a lot of the work for you, but it’s always a good idea to double-check their work or have a professional look at it. One small mistake can completely de-monetize your site.
Google has been a big proponent of ads.txt since its launch. It has even gone so far as to make ads.txt a central feature of Google AdSense. If you’re using AdSense, you can download an ads.txt file directly inside your AdSense account.
Here’s the process:
- Inside your AdSense account, click Sites.
- Click the downward arrow and select "Create an ads.txt file for..."
- Add any ad networks you are using in addition to Google’s. (Google’s ad network is automatically added to the file.)
- Click Download.
How to Implement Ads.txt as a Publisher
With your ads.txt file created, all you have left to do is to implement it on your site. Because there are dozens of content management systems (CMSs), hosting platforms, and website management methods, implementation of ads.txt can look a lot of different ways. But the most basic idea of implementation is to get the file onto your site as its own page fed directly off of the root domain.
In other words, however, your web host or CMS allows you to create new pages is very likely the way you will get your newly created ads.txt file onto your site and active. Below, we take a look at the ads.txt implementation process for some of the most common platforms.
Ads.txt on WordPress
The lovely thing about WordPress is that it makes it so easy to customize your site. That’s likely a big part of the reason why 43% of all websites use WordPress as their CMS as of December 2021. If you’re one of the 43%, you may have an easier time than the remaining 57% getting ads.txt on your site.
WordPress website customization is all about plugins. These are the little apps and tools you download to use on your site. Several plugins were designed to help publishers manage ads.txt. Each of these plugins will have a slightly different approach, but in general, the process is simple:
- Download the ads.txt plugin of your choice and activate it.
- Find the ads.txt plugin in the left-hand sidebar of your WordPress dashboard.
- Go into the portion of the plugin interface that allows you to modify or upload your ads.txt file.
- Upload the file and save.
That’s typically it for WordPress ads.txt plugins. From there, the ads.txt page should be live on your site. You can check whether it’s live by typing your domain name followed by /ads.txt/ into the URL bar and making sure your ads.txt file pops up.
Ads.txt on Squarespace
If you’re using Squarespace to manage your website, you may find that the process is a bit more complex than it is for WordPress. That’s because you have to do some semi-fancy workarounds to make ads.txt work in Squarespace’s environment, which isn’t designed to accommodate ads.txt.
Essentially, you will need to upload your ads.txt file to your Squarespace site as a file — not a new page. With the file uploaded to the CMS, you can now add it to a new page you create. But you’re not done.
Then, you need to view the page that contains the ads.txt file, right-click the file and select “Copy link address.” This gives you the address where your ads.txt file lives on your site. From there, you have to set up a redirect to link the actual location of the ads.txt file with the preferred root domain URL for ads.txt: /ads.txt/.
Ads.txt on Joomla
Joomla is another website management platform that uses plugins, and there are a few to choose from that will help you get your ads.txt file onto your site. Basically, you download and activate the plugin, enter the plugin interface and upload the ads.txt file.
Ads.txt on Drupal
Drupal doesn’t use plugins, but it uses extensions and modules, which operate in basically the same way. To get ads.txt on your Drupal site, you need to download Drupal’s ads.txt module. Log in to your Drupal interface and select “Enable newly added modules.” Find ads.txt under Advertising and click Install.
Find the Configuration page for the ads.txt module and replace the example text with your ads.txt file, and you’re done.
How to Verify and Validate Ads.txt
At the end of the day, an ads.txt file is a piece of code. Like any piece of code you may try to write, it’s absolutely brimming with opportunities to make a mistake. And in digital advertising, a single mistake can cost you an obscene amount of money in lost advertising because your authorized sellers may not register as authorized. That means most buyers won’t purchase your inventory from them.
Outside of the simple code mistakes you could make, there are plenty of ways to mess ads.txt up during the actual implementation process. In other words, even if you think you’re good, you need to make sure.
There are two basic ways to make sure, and they’re both relatively simple:
- Make sure the file is on your site. If the file isn’t even there, you’re going to have an immediate problem. Fortunately, this one’s easy to check. Simply type your domain name followed by /ads.txt/, like this: https://domain.com/ads.txt. Check what loads on that page. It should be your ads.txt file.
- Validate that the file is written correctly. If you’re not a professional developer, you may need a little help making sure you entered everything into your ads.txt file correctly. Mark this down as #9,452,127 in the list of gifts from the internet: plenty of very nice people have created free, reliable ads.txt validators you can use. Simply type “ads.txt validator” into Google, and you’ll see. Most ask you to enter your ads.txt URL or upload the file directly. From there, they return a list of errors in your ads.txt file.
Those methods will help you find the errors. Fixing them, unfortunately, is an entirely different matter. In this regard, some ads.txt validators are better than others at giving you the specifics of what went wrong. Some of the most common ads.txt file errors include the following:
- Pasting text into the document with formatting (rather than without formatting), can add extra characters that break the code
- Forgetting one of the required fields for an authorized seller
- Improperly adding spacing that breaks the code
Of course, there are tons of other errors you might make, but those are some of the most common.
You can visit the complete ads.txt resource center or dive deeper into any of these related articles:
- How to Create an Ads.txt File
- How to Add an Ads.txt File to Your CMS
- Ads.txt for OTT
- App-Ads.txt: Creating an Ads.txt File for Your App
- 5 Tips for Getting Your Ads.txt Syntax Right
- Generating Ads.txt AdSense Code
- Ads.txt Tools: Ads.txt Managers, Ads.txt Validators and Ads.txt Generators
- 3 Advanced Ads.txt Use Cases
Is Ads.txt Required?
No. Ads.txt is not mandatory in general, but the majority of sellers may require you to have it if you want to participate in their demand ecosystem. It’s also considered a common courtesy in the digital advertising world — and a way to show that your inventory is of higher quality than that of your competitors who don’t use ads.txt.
What is a Publisher ID?
The publisher ID is one of the required fields for each line of your ads.txt file. This is your unique identifier number tied to your account on the SSP or exchange you are trying to authorize to sell your inventory. Google AdSense automatically adds your publisher ID to your ads.txt file (when you download it inside your AdSense dashboard). Other sellers may have different processes for finding your publisher ID within their platforms.
How Do I Add an App-Ads.txt File for My App?
The app-ads.txt implementation process is largely the same as the ads.txt implementation process. In fact, you’re still going to have to use a website to do it. This website has to be the one linked to from your app inside the app stores — your developer site. You still upload the app-ads.txt file to your root domain, and buyers use it to verify your inventory before purchasing it.
How Can I Add New Sellers After My Ads.txt File is Live on My Site?
If you’re not using dynamic ads.txt, which simplifies the ads.txt update process, you should consider it. But if you’re not quite there yet, the process of updating the ads.txt file is the same as uploading it in the first place. You make the changes to your ads.txt file, save them and use your CMS to upload the updated ads.txt file to the same place as the old one, replacing it.
Playwire: Your Guide to Ads.txt and So Much More
Ads.txt is just one part of digital advertising, but it’s a part that is growing in importance every day. As ad fraud continues to plague the industry and advertisers start to show preference for publishers who have ads.txt files, you really can’t afford to skip over this important step in your digital advertising plan.
But who has the time — or the energy and technical knowledge, for that matter? Publishers are already stretched thin, and we know all you really want to do is make great content. That’s why Playwire is here. As part of our revenue amplification platform, we manage your ads.txt file so you don’t have to.
In practice, that means you don’t ever have to think about ads.txt again. But it also means something else — something more important. Your revenue gets to where it needs to be, to the absolute maximum, and you can focus on creating the content your audience loves you for.
Sound good? Great — we think so, too. And we’re ready to get started. All you have to do is reach out to us. Just contact us online to put ads.txt in the rearview mirror and more revenue on the horizon.