Curious to know how to change package name in Android Studio? It’s quite easy and so I have laid out some steps.
The only way you can change the package name of an Android application is with the help of Android Studio. Developers use it as it has swift tools that help build apps on every type of Android device. You might want to download source code from the internet and rename the package name that suits your application. This guide is the only thing you’ll need in order to know how to change package name in Android Studio. So, let’s dive in!
How to Change Package Name in Android Studio
Step 1: Launch the Android Studio.
Step 2: Ensure that you are seeing the project in the Android view.
Step 3: If not, click on Packages > Android.
Step 4: Open Settings and deselect Compact Empty Middle Package.
Step 5: You can now see that the package folder is now broken into parts.
Step 6: Right-click on the very first package folder > Refractor > Rename.
Step 7: You will get a warning but go ahead anyway.
Step 8: Click on Rename Package once again.
Step 9: Now, enter your domain name in the empty box. This will be your package name.
Step 10: At the bottom of Android Studio, you’ll see a pop-up Find Refactoring Preview.
Step 11: Now click on Do Refactor.
Step 12: You’ll see the change in the package domain name of the App.
Step 13: Now change the domain extension and App folder name according to your requirement.
Step 14: Open build.gradle (Module: app) under Gradle Scripts.
Step 15: Change the application ID and click on Sync Now.
You have now changed the application package name in Android Studio.
What is the Android Package name?
Android Package name is a novel title given to an application to identify it. Usually, the package name is in the format domain. However, the developer of the app is free to choose a name.
Can I change the Android package name?
Yes, you can change the Android package name with the help of Android Studio.
This is how to change package name in Android Studio. Android Studio is a valuable tool for Android developers and using it to tweak Android apps is quite easy.