📅 2020-Jan-05 ⬩ ✍️ Ashwin Nanjappa ⬩ 🏷️ google adsense ⬩ 📚 Archive
AdSense is the Google service that helps you serve advertisements on your website.
Signup: The first step is to sign up for the service. I used my existing Google login for this.
Country or currency problems: I had a problem after signup because I had moved from SG to USA and Google was still showing me as SG in AdSense with no place to change that. I finally solved this by going to the Google Play Store app on my Android device and changing the country there. Google asked for my US credit card information to make this change.
Add website: Add your website to AdSense by providing its URL. You do not necessarily need to have your own domain. Google can serve ads on pretty much any subdomain or plain URL. This allows you to monetize pretty much any webpage, even if it is hosted by some other service you do not own or pay for.
Auto ads: This is one type of ads you can choose for your website. In this case, Google decides which type, size and number of ads to serve on each of the webpages in your site. If you choose this option, Google provides a small piece of code that you need to add to the header section of every webpage HTML. The code looks like this:
<script data-ad-client="ca-pub-XXXXXXXXXXXXXXXX" async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js">
</script>
Pick your own ad units: The other option is to design your own ad units: display ads, in-feed ads or in-article ads. If you go this way, Google provides a corresponding piece of code that you will need to insert at the exact location in the HTML where you want that ad unit. This is more complicated compared to auto ads, but provides more fine-grained control to you.
Preview: Using this feature you can view where Google will place ads on each of your webpages. You can choose to customize location of ad placement on a per-webpage basis and can also choose to exclude certain webpages from ads.
ads.txt: After you add the code to enable ads on your website, Google takes a few days to do their tests on your webpages. Once this is done, the AdSense website will instruct you to add a ads.txt
file at the root of your website. The text of this file reads something like this:
google.com, pub-XXXXXXXXXXXXXXXX, DIRECT, SOMEHEXCODEHERE_
Ads go live: A few days after you added the ads.txt
, Google finally starts showing ads on your website. You will be able to view the ads when you visit your own website, even if you are logged into AdSense. You will also see that the reports section of AdSense website get populated with impressions and other stats.
Revenue: Google will only pay you once the collected revenue passes a certain threshold.