ADB Shell: List All Installed Apps
Managing apps on Android can be done in many ways, and one of the most direct methods is using the command line.
The adb shell list installed apps command provides a powerful way to see every application on a connected device without opening the settings menu.
Understanding ADB and Its Capabilities
ADB, or Android Debug Bridge, is a versatile command-line tool that lets you communicate with a device.
It is commonly used by developers and power users to install apps, copy files, and run shell commands remotely.
Accessing the Device Shell
To interact with the operating system of the phone, you need to open a shell session.
This is done by typing adb shell, which gives you a prompt similar to a Linux terminal where you can execute any command the device supports.
Listing Applications via Package Manager
The package manager is the Android system component responsible for installing and managing apps.
By combining adb shell with pm list packages, you can retrieve a simple list of all package names installed on the device.
Common Command Variations
There are several ways to filter and format the output to match your specific needs.
Knowing these variations helps you quickly find system apps, third-party apps, or debug specific software.
Filtering for User Applications
To see only the applications installed by the user, you can filter out the system packages.
This results in a cleaner list that includes just the apps you downloaded from the Play Store or other sources.
Filtering for System Applications
System apps are pre-installed by the manufacturer and are essential for the device to function properly.
Using a specific flag allows you to isolate these core components from the user-installed software.
Displaying Human-Readable App Labels
Package names are technical identifiers, but they do not tell you the app name at a glance.
Switching to a label-based listing provides the display names, making it easier to identify specific programs at a glance.
Exporting the List to a File
For documentation or analysis, you might want to save the list to your computer.
By redirecting the output to a text file, you create a permanent record of all installed packages that you can review later.
Troubleshooting and Advanced Usage
Sometimes the command does not return results due to connection or permission issues.
Checking USB debugging, driver installation, and device authorization is the first step in resolving these problems.
Handling Errors and Permissions
If the device is not authorized, the command will hang or display an error message.
Always confirm that the prompt on the phone appears, allowing the computer to interact with the operating system.
Piping Output to Other Tools
You can enhance the raw list by using standard Linux tools like grep or find.
This allows you to search for specific keywords or count the total number of apps installed on the device.
Mastering these terminal techniques gives you granular control over your Android device beyond what the UI allows.
Experimenting with these commands in a safe environment helps you understand the structure of your system and manage your digital life more efficiently.