Welcome to AdSense Help Center. Due to the holiday season our support is currently unavailable from 17th December to 4th January. We encourage you to visit our Help Center and community forums for additional resources. We apologize for any inconvenience this may cause and appreciate your patience during this time.

Code implementation guide

Where to place the AdSense code in your HTML

After you've generated the AdSense code, you need to paste it between the <head> and </head> tags of your site. We recommend you place the AdSense code on every page across your site to get the most out of AdSense.

WordPress user? Get help with adding AdSense code.

The following examples show you where to place the AdSense code:

Example HTML page before the AdSense code has been added

<html>
<head>
This is the head of your page.
<title>Example HTML page</title>
</head>
<body>
This is the body of your page.
</body>
</html>

Example HTML page with the AdSense code added in the <head> tag

<html>
<head>
<script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-1234567890123456" crossorigin="anonymous"></script>
This is the head of your page.
<title>Example HTML page</title>
</head>
<body>
This is the body of your page.
</body>
</html>

Note: This is sample code only, please don't use it in your own site's code.
Was this helpful?
How can we improve it?

Need more help?

Sign in for additional support options to quickly solve your issue

Search
Clear search
Close search
Google apps
Main menu
Search Help Center
true
157
false