When you create your first ever application or select a new project in Android Studio you must have seen that the default color theme of the Titlebar (Toolbar) is purple. If you want to change the color theme, follow the below steps,
- Go to res folder,
- Now go to values -> colors.xml
- Now add the new colors that you want, example,
<color name="grey">#888888
- Now go to themes folder,
- Open themes.xml file
- Change the colorPrimary value to @color/grey
<resources xmlns:tools="http://schemas.android.com/tools"> <style name="Theme.MyApplication" parent="Theme.MaterialComponents.DayNight.DarkActionBar"> <item name="colorPrimary">@color/grey</item> <item name="colorPrimaryVariant">@color/purple_700</item> <item name="colorOnPrimary">@color/white</item> <item name="colorSecondary">@color/teal_200</item> <item name="colorSecondaryVariant">@color/teal_700</item> <item name="colorOnSecondary">@color/black</item> <item name="android:statusBarColor" tools:targetApi="l">?attr/colorPrimaryVariant</item> </style> </resources>
- Launch the app in emulator to see the changes.

Note: You can change the other theme colors here such as statusBarColor, colorSecondary, colorSecondaryVariant and so on in the same way!
Happy Coding!!
Have Questions? Post them here!
- Android Error Unexpected cast to Button: layout tag was FrameLayout
- ADT quit unexpectedly error on Mac OSX Android Eclipse SDK
- Parsing Data for android-21 failed unsupported major.minor version 51.0
- Android Studio Ctrl Shift o auto import not working
- java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant) with this activity.
- Android : How to make TextView Scrollable
- This class should be public (android.support.v7.internal.widget.ActionBarView.HomeView) Lint Error
- Integrating Android Facebook SDK 3.17.2 Tutorial
- Android R Cannot Be Resolved To A Variable
- Android : Exception raised during rendering: action_bar API 22
- How to take screenshot on Android
- Read Text file from SD Card : Android Programming
- How to make Android EditText not editable
- Your Android SDK is out of date or is missing templates. Please ensure you are using SDK version 22 or later.
- The declared package does not match the expected package Eclipse
- Can't Run SDK Manager find_java.bat issue
- What is Android Toast.LENGTH_SHORT and Toast. LENGTH_LONG durations
- Android Emulator Soft Back button action using Computer keyboard
- Multiline EditText in Android Example
- Use 5G Network on Android Emulator
- Make Android TextView Clickable like Buttons
- How to empty trash in Android Device
- Android : Execute some code after back button is pressed
- Disable Fading Edges Scroll Effect Android Views
- How To Disable Landscape Mode in Android Application
- Whats new in Python 3.10 Pre-release - Python
- Read file from Windows CMD (Command Line) - Windows
- [Fatal Error] XML The markup in the document following the root element must be well-formed. - Java
- How to highlight the current line in Notepad++ - NotepadPlusPlus
- Android is starting optimizing... app 1 of 1 - Android
- Spring Boot JDBCTemplate Upsert Example (batch insert or update if exists) - Java
- How to add Multiple Rulers in Sublime Text - Sublime-Text
- scp: ssh: connect to host xxxx port 22: Connection refused Error - Linux