Ads.txt error in adsense [SOLVED]

You opened your Adsense and suddenly a red error box appears with this line

"Earnings at risk - One or more of your ads.txt files doesn't contain your AdSense publisher ID. Fix this now to avoid severe impact on your revenue."

Ads.txt error in adsense and how to solve this
Ads.txt error in Adsense and how to solve this




You do not need to worry about this just do the following steps and your Adsense account will be absolutely fine. First of all, we have to know that what this error actually is.

What is ads.txt

It is a text file. Ads.txt is an initiative from the Interactive Advertising Bureau Tech Lab (IAB) to promote and improve transparency in programmatic advertising. Through this sellers can easily tell buyers that who is selling ads on their site.


Why we need to create an ads.txt file on our site

You are required to do this to publicly declare that Google is authorized to sell ads on your site.

How to solve the ads.txt error in Adsense


ads.txt error in adsense and how to solve this

You can solve this error by just following the steps.
  • Create a text (.txt) file.

  • Include the following line: google.com, pub-0000000000000000, DIRECT, f08c47fec0942fa0

  • Important: Make sure you replace pub-0000000000000000 with your own publisher ID.

  • Host your ads.txt on your root domain (for example, https://example.com/ads.txt).

Open your notepad copy the text which is shown above paste it into your notepad save this file as ads.txt.
Now open your hosting account and upload this file in your root domain.

If you are using any other platform like blogger then follow the steps below
Copy the given code and go to
blogger > the site blog which is told by Adsense to put the file in > settings > search preference > custom ads.txt and click on yes put the code in and save.

ads.txt error in adsense and how to solve this

Now, wait for 24 hours to update google servers after that your error will be solved.

Author: Faizan Athar
Disqus Comments