ArtsAutosBooksBusinessEducationEntertainmentFamilyFashionFoodGamesGenderHealthHolidaysHomeHubPagesPersonal FinancePetsPoliticsReligionSportsTechnologyTravel
  • »
  • Technology»
  • Communications»
  • Smartphones»
  • Android Phones

Android Admob setup - Android Developement

Updated on February 4, 2012

When you are working on developing your own applications for mobile phones, it is good to monetize them to generate income out of it. Admob is very useful for this purpose both in Android development and iOS development. This tutorial is for showing how to setup the admob for android applications.

First step in doing that is to create an account at Admob to get your Admob publisher ID.

Once you receive your Admob ID, proceed with the below steps for setup.

Open your AndroidManifest.xml file and add a new activity for google AdActivity as shown in the below code.

<activity android:name="" 

It is very important that the android:configChanges should have all the values shown above. If you miss any value, it may result in a error such as "You must have AdActivity declared in AndroidManifest.xml with config changes".

next step is to change your main activity xml where you want to have the ad to be shown. Add the below code as shown.


I am currently using GoogleAdmobSDK of 4.3.1 version and able to run the ads successfully using the build target as Android-13 and with miniSDKVersion as 7.

If you encounter any errors, look at the LogCat to identify the real cause.

I hope this article is helpful to you.


    0 of 8192 characters used
    Post Comment

    • profile image

      tatimon 6 years ago

      theres another great potion for monetizing new apps, and registration + downloading SDK take sno more than 5 min :)