How to hide title bar and status bar in Android application
This post is going to be very short one and here we will discuss about how to hide title bar and status bar in Android application. If you look at Gaming applications like ‘Cut the rope’, ‘Angry birds’ and more in your android device, applications are displayed in full screen view which covers entire area of the display to provide more user experience.
We will develop a sample application which has no title bar and no status bar.

Either you can proceed with the below listings, or download code.
- Create new android project [File >> New >> Android Project] with project name FullScreenExample
- Click next and select target android device version [I chose version 2.2]
- Click next and enter package name – ‘com.prgguru.android’
- Click finish
We can achieve full screen view in either of the two ways:
- Include full screen theme in AndroidManifest XML
- Include Window settings in onCreate method of Activity class
Include full screen theme in AndroidManifest XML:
<activity android:name=".YourClassName" android:theme="@android:style/Theme.NoTitleBar.Fullscreen"> </activity>
Just change .YourClassName to the Activity class name ( in our application it is ‘FullScreenExampleActivity’).
Include Window settings in onCreate method of Activity class:
package com.prgguru.android;
import android.os.Bundle;
import android.app.Activity;
import android.view.Window;
import android.view.WindowManager;
public class FullScreenExampleActivity extends Activity {
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
//No title bar is set for the activity
requestWindowFeature(Window.FEATURE_NO_TITLE);
//Full screen is set for the Window
getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,
WindowManager.LayoutParams.FLAG_FULLSCREEN);
setContentView(R.layout.main);
}
}
Demo:
Congratulations, We are done.
Let us test the application:
Right click on the project >> Run as >> Android application >> Choose emulator or device
You could see this screen:
*apk in Android is the installation file simliar to exe in windows.
I hope you enjoyed the post!! ![]()







hi udhay,
how to suppress dictionary hints while entering text in textarea for android…………….
Add android:imeOptions=”textNoSuggestions” attribute to EditText tag which will suppress suggestions. Take a look at this link – http://stackoverflow.com/questions/7430816/how-to-suppress-dictionary-hints-while-entering-text for more information.
How to hide title bar and status bar in Android application all versions,plaese give suggetion …………………..
Hi,
It is working perfectly in other Android versions.
Please give a try.
is this fullscreen view working on android 4.0 is fine,but this full screen view not working on android 3.2.how to achieve full screen view on android 3.2.please give suggestion to me as early as possible.your example running on andriod 4.0,not in android 3.2……………….
Just use Android Theme.NoTitleBar.FullScreen.