The previous pages described various ways you can create a compelling search engine for your website or a collection of websites. This page shows you how you can monetize your search engine by associating your AdSense account with your search engine.
This page includes the following sections:
If you have spent some time tweaking a search engine, such as a vertical search engine that specializes on wine and other vinicultural interests, you can make money with it by connecting it to your Google AdSense account. AdSense is a free program that gives you a fast and easy way to display relevant, unobtrusive Google ads on your result pages. When users click on an ad in your search results, you get a share of the ad revenue. To learn more about the AdSense program, see its Help Center.
If you do not have an AdSense account, you can apply for one in the Make money tab of the control panel. But if you already have an AdSense account, do not create a new one; just associate the existing one with your search engine. All search engines in your account will automatically be associated with that AdSense account.To learn more, see the Getting Started page.
You can also associate your existing AdSense account with your search engine in the context file. This entails the following steps:
If you already have an AdSense account, you can find your unique AdSense publisher ID by signing in to your AdSense account. Your publisher ID number is above the help search box in the top corner. Alternatively, you can find your publisher ID within the generated AdSense code that you can insert in the HTML code of your webpage. Locate the line that has: google_ad_client="pub-1234567890123456"; the number is the ID.
If you want to get the ID programmatically, see the Programmatically Creating Custom Search Engines page.
You can associate a search engine with an AdSense account by adding the AdSense element in the CSE XML specification, as shown below:
<CustomSearchEngine id="my_first_cse" creator="0123456789" keywords="cars" language="en">
<Title>Automobile Search</Title>
<Description>Car Search</Description>
<Context>
<BackgroundLabels>
<Label name="_cse_my_first_cse" mode="FILTER" />
<Label name="_cse_exclude_my_first_cse" mode="ELIMINATE" />
</BackgroundLabels>
</Context>
<LookAndFeel nonprofit="false" />
<AdSense>
<Client id="pub-9876543210">
<Channel id="1234567890"/>
</Client>
</AdSense>
</CustomSearchEngine>
The XML has the following hierarchy:
CustomSearchEngine
TitleDescriptionContextLookAndFeelAdSense
Client id
Channel idThe AdSense element has a child element, Client. If you have created a channel for the search engine, Client can have the Channel child element.
Channels enable you to view detailed reporting about the performance of your search engine. You can only associate one channel per custom search engine. If you have multiple search engines, create separate channels to track the performance and revenue of each of search engine. To learn more about channels, see the Help Center for AdSense.
Congratulations, you've read through the developer's guide. You can kick back and reward yourself with some fine chocolate, or—if you haven't already— you can start creating and customizing search engines. If you know how to program and are familiar with HTTP, you can dynamically create custom search engines.
< Back to Designing the Look and Feel | Forward to Programmatically Creating Custom Search Engines >