Display ads on login-protected pages
Once your application has been approved, you can display Google ads on pages behind a login by creating a crawler login. This will give the AdSense crawler access to visit your pages and deliver targeted ads.
To do so, you'll need to provide login details for your site, and verify your site using the Search Console and other Webmaster resources provided below. Please follow these steps.
- Sign in to your AdSense account.
- Click Account.
- Click Access and authorization, then click Crawler access.
- In the "Crawler access" section, click Add a login.
- Provide the login details that our crawler will use to access your site.
You'll need to provide the following information:
- Restricted directory or URL: The URL that is blocked from our crawler's access.
- Login URL: The URL that our crawler should visit to sign in.
- Login method: The method your site uses to authenticate users who log in. POST and GET are common authentication methods.
- Parameters: The credentials that our crawler will use to sign in (for example, your site's username and password). For GET and POST methods, please enter the URL parameter key-value pairs such that your server will return a cookie for logged-in access.
- Sign in to Search Console using your Google Account. You must be using your Google Account in order for any changes you make in Search Console to be reflected in your AdSense account.
- Add a site to your account by following these instructions. This should be the site that you'd like to allow our crawler to access.
- After you've followed the instructions, on the next page, choose "Verify your site" under the >> Next step section. If you can't find it, return to the Search Console homepage and follow these directions.
Once you've verified your site, the login details that you have provided should allow the AdSense crawler to reach your pages and provide targeted ads.