Android Google Map API V2 Blank Screen-ThrowExceptions

Exception or error:

Hi I recently followed Vogella’s tutorial on Google Map API v2. The code is similar to his. But for some reason the map shows up blank and the logcat shows no error either. I also followed this video to get the SHA1 finger print then I put the API key inside the manifest file. I used the debug keystore C:\Users\\debug.keystore which is also the default debug keystore located in Eclipse -> Windows -> Preference -> Android -> Build.

I also generated a new API key and it still doesn’t work.

Manifest file:

<manifest xmlns:android=""
    android:versionName="1.0" >

        android:targetSdkVersion="15" />

        android:protectionLevel="signature" />

        android:required="true" />
    <uses-feature android:name="" />
    <uses-feature android:name="" />
    <uses-feature android:name="" />

    <uses-permission android:name="android.permission.INTERNET"/>
    <uses-permission android:name="android.permission.CAMERA"/>
    <uses-permission android:name="android.permission.INTERNET"/>
    <uses-permission android:name="android.permission.VIBRATE"/>
    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
    <uses-permission android:name="android.permission.SET_DEBUG_APP"></uses-permission>
        android:theme="@style/AppTheme" >
            android:label="@string/title_activity_home" >
                <action android:name="android.intent.action.MAIN" />

                <category android:name="android.intent.category.LAUNCHER" />

        <activity android:name=".ScanActivity"/>
        <activity android:name=".MapActivity"/>
        <activity android:name=".BarcodeHelper"/>
        <activity android:name=".JsonHelper"/>

            android:value="my api key" />


This is my layout file for the map activity:

    <RelativeLayout xmlns:android=""
    tools:context=".MapActivity" >

        class="" />


This is my map activity:

public class MapActivity extends Activity { static final LatLng HAMBURG = new LatLng(53.558, 9.927); static final LatLng KIEL = new LatLng(53.551, 9.993); private GoogleMap map; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_map); map = ((MapFragment) getFragmentManager().findFragmentById( .getMap(); Marker hamburg = map.addMarker(new MarkerOptions().position(HAMBURG) .title("Hamburg")); Marker kiel = map.addMarker(new MarkerOptions() .position(KIEL) .title("Kiel") .snippet("Kiel is cool") .icon(BitmapDescriptorFactory .fromResource(R.drawable.ic_launcher))); } @Override public boolean onCreateOptionsMenu(Menu menu) { // Inflate the menu; this adds items to the action bar if it is present. getMenuInflater().inflate(, menu); return true; } }


How to solve:

You have couple of permission issues with your manifest. First, in the following you need to replace the package name with your package, you also need to as a uses-permission

        android:protectionLevel="signature" />

per your package name, should be —

<uses-permission android:name="com.example.barcodelibrary.permission.MAPS_RECEIVE"/>

Finally, you seem to be missing the following permissions from the specifying permissions section of the Getting Started guide

<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name=""/>
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>


For me it turned out that I didn’t enabled the Google Maps Android API v2. We were using another Google Maps API which I assumed to be the same.


I had to add the correct SHA-1 certificate fingerprint to my Google Developer Console.

  1. Display the current fingerprint: keytool -list -keystore ~/.android/debug.keystore

  2. Copy the fingerprint (e.g. 48:6F:55:B7:C5:E4:54:E1:29:D5:E1:E1:E2:A8)

  3. Add it to your credentials for that particular app in Google Developer Console


I ‘ve got a similar problem with the map. After fixing all lib and key problems, I just saw a white sreen labled with “Google”.
The problem was, that I put the MapFragment into a ScrollView. After removing the ScrollView everything works fine. I can see the map.


if it didn’t work though,follow this

Solving the blank screen issue on maps:
Hi there ,i have been through this blank screen for a very long time and tried out all solutions u can imagine.Now it solved and the steps were:

1-Go through all steps of this tutorial carefully.

2-If the blank screen still the same ,delete you debug key store file that exists in
c:\Users\\debug.keystore <– delete this file

3-On the eClips IDE rebuild your app so it will automatically re create this file.
4-On eclips go to Window–>preferences–>android–>Build
copy the fresh generated SHA1 and then follow the normal key generation steps .
5-Run on your real device ,and i hope you’ll see your map 🙂


You Must Run your app in amulator having Following Configuration….
1) Google API(x86 System image)
2) select checkBox indicating Use Host GPU..


Set custom keysote to the same as default one (Eclipse). And register a API key in google console as it’s said in documentation.


Most people forget to activate the Google Maps Android API V2 in the developer console, I activated it and voila, my map appeared.


In my case it was an existing app that I cloned from GitHub and did not change the API Key. What worked for me is to enable the SHA-1 of my signing certificate. Follow these short instructions to get a SHA-1 fingerprint.

Then I had the main developer add my SHA-1 fingerprint to the authorized packages for his relevant API Key here. Then I did the build again in the same way and it worked.


my answer in other post is what actually works for me, i paste the App signing certificate sha-1


Android Studio:
make sure you put your key in the right hierarchy

enter image description here


I have a similar issue, where debug was ok, but blank screen on release. API keys were fine.

What worked is replacing this :

            android:value="@string/google_maps_key" /> 

By this


Add directly your api key without ressource string

Leave a Reply

Your email address will not be published. Required fields are marked *