CodeSteps

Python, C, C++, C#, PowerShell, Android, Visual C++, Java ...

Google Adsense – How to fix “Earnings at risk – One or more of your sites does not have an ads.txt file” Warning?

When I opened my Google Adsense account, suddenly it displays below message. Google Adsense never shown before this message on my Dashboard; this is the first time I am seeing the message.

Earnings at risk - One or more of your sites does not have an ads.txt file. Fix this now to avoid severe impact to your revenue.

I have started digging into it, to fix to NOT to show this message on my Adsense Dashboard. And finally I found the solution and thought share what I have done through this Article.

Why this Warning message?

Google is following the Global Technical Standards to avoid the frauds in the digital advertising to ensure that the ads displaying on your website are through the authorized sellers. This will improves your ad revenue.

Google verifies whether your website is following this standard or not and if it it is NOT, it throws the Warning message on your Google Adsense Dashboard.

How to fix this then?

It is simple. You need to let Google know what are the authorized sellers from which you are allowing them to display the ads on your website(s). This can be done through mentioning the list of Authorized Digital Sellers through a text file ads.txt; where ADS stands for Authorized Digital Seller.

Step 1. You need to create this ads.txt file in the root directory where you have installed your website.

Step 2. Once you have created the file, you need to add the list of authorized sellers; and each seller details have to be in a separate line. The seller details are like below;

<Domain Name of the Seller>, <Publisher Id>, <Type of Relationship with the Seller>, <TAG ID of the Seller Account>

Observer that, each field is separated by a comma (,) and each seller details should be listed in a separate line.

For example, for Google Ads the entry should looks like below;

google.com, pub-xxxxxxx, DIRECT

Ensure to replace pub-xxxxxxx with the Publisher ID of your Adsense Account. And if you are directly managing your Account, you can use DIRECT as the entry; otherwise, you need to use RESELLER as the relationship entry.

TAG ID is an optional field. If you know the TAG ID of the Seller Account, you can specify the TAG ID at end. And ensure the each fields is separated by a comma (,).

Step 3. Once the details are added, save the ads.txt file.

Step 4. If you own multiple websites; ensure to add ads.txt file for each of the website. Follow the steps 1 to 3, for all of your websites to add ads.txt files.

Step 5. Don’t you know in how many websites you are using your Adsense Account to display the Ads? Just you click on the Sites link from the Google Adsense Dashboard. It shows list of websites, where you are using your Adsense Account, to display the Ads.

Step 6. Once you add the ads.txt files in all of your websites, give some time to Google to crawl your ads.txt file to recognize your websites are following the Global Technical Standards to display the ads on the websites. Usually it will take 24 hrs to crawl the website.

Step 7. Ensure the ads.txt file is accessible from your root domain. For example, https://your-domain-name.com/ads.txt.

Now you won’t see the “Earnings at risk” Warning message in your Adsense Dashboard.

Still are you seeing “Earnings at risk” warning message?

Then, you need to troubleshoot the changes you done. You can skip below steps, if you are not seeing this warning message, after adding ads.txt file.

Test 1. Ensure no invalid characters or format errors in the ads.txt file.

Test 2. Verify whether ads.txt file is accessible from the root domain of your website. If it is not accessible, response will be HTTP 404 error. If it is accessible, the response will be HTTP 200 status. You can verify this through “URL inspection” feature in Google Search Console.

Test 3. Ensure ads.txt file is not blocked in robots.txt file for crawling. If this is blocked, Googlebot can’t crawl the file. You need to allow Googlebot to crawl the ads.txt file.

And also, ensure it is accessible via both HTTP and HTTPS.

Test 4. Verify whether you have added ads.txt file for all your website domains. You can see, list of sites where this file has to be added; through Sites feature from Google Adsense dashboard.

You can correct the file or you can remove the domains where it is not required to add this file. Otherwise, you will see the warning alert in Google Adsense dashboard.

Test 5. Wait for some time, Googlebot to crawl the file. Usually it will take 1 to 2 weeks of time.

Repeat these steps, to ensure to remove the warning alert from your Google Adsense dashboard.

) Peter (

Google Adsense – How to fix “Earnings at risk – One or more of your sites does not have an ads.txt file” Warning?

7 thoughts on “Google Adsense – How to fix “Earnings at risk – One or more of your sites does not have an ads.txt file” Warning?

  1. I already add those to my site, but there is one that is already gone (didn’t renew) and it’s still showing for that site. Do you know how can I remove that warning? Appreciate the help!

  2. I’m getting this error message on my Blogger blog and I added the ads.txt file a couple of years ago! I just checked and it’s still there. Google seems to frequently send me these scary warnings and error messages and there is nothing wrong … I’m a webmaster, too. LOL. Anyone else getting this error but the ads.txt file has been securely in place for quite a while?

  3. Hello, I see this message on my site too. I have already corrected it by adding the associated file. However, although it has been a few days, I still show the message.how long I have to wait, what else can I do?

    Thank you

    1. Hello,
      You need to wait till Google crawls the ads.txt file. Also ensure to add this file to all of your sites. You can see the list of sites, by clicking Sites link from Adsense account.
      Also ensure your site’s robots.txt file NOT blocking to crawl the ads.txt file.
      Thanks,

  4. This doesn’t restrict displaying the ads. Your ads may be blocked or may be you have a network firewall which is blocking the ads.
    Try accessing your website from another network & another browser.
    When you modify your ad settings, it will take some time to reflect with your changes. Wait for some time and try.

Leave a Reply

Your email address will not be published. Required fields are marked *

Scroll to top