When you sideload an APK that isn’t from the Play Store, the biggest question is: Is this file genuine? Android enforces a cryptographic signature on every app package, but the signature is only useful if you actually check it before installing. This tutorial shows you, step by step, how to extract an APK from any Android phone (no root required) and verify its signature with the official apksigner tool that ships with the Android SDK.
Every APK is signed with a private key belonging to the developer. During installation Android compares the embedded signature with the one stored on the device. If the signatures don’t match, the system blocks the install. However, a malicious actor can re‑package a legitimate app, sign it with their own key, and distribute the altered file. By verifying the signature yourself you can confirm that the APK you hold matches the original developer’s certificate.
USB debugging (Settings → Developer options → USB debugging).apksigner binary.apksigner binary is already part of the SDK.C:\adb on Windows or ~/adb on macOS/Linux.PATH so you can call adb from any terminal.
# Windows (PowerShell)
$env:Path += ";C:\adb"
# macOS / Linux (bash)
export PATH="$PATH:$HOME/adb"
adb version
You should see something like Android Debug Bridge version 1.0.41.apksigner tool lives in the build-tools directory of the full Android SDK. If you don’t have the full SDK, download the Command‑line tools and install the latest build-tools package:
# Example for macOS/Linux
mkdir -p $HOME/Android/Sdk/cmdline-tools
cd $HOME/Android/Sdk/cmdline-tools
# unzip the command‑line‑tools zip here
# Then use sdkmanager to install build‑tools
$HOME/Android/Sdk/cmdline-tools/latest/bin/sdkmanager "build-tools;33.0.2"
After installation, apksigner will be at $HOME/Android/Sdk/build-tools/33.0.2/apksigner. Add that folder to PATH as well.
apksigner binary is also bundled with the bundletool zip used for Android App Bundles. Extract apksigner from there if you don’t want the full SDK.Android stores installed apps in /data/app (for user apps) or /system/priv-app (for system apps). Access to these folders is restricted, but you can still retrieve the APK via adb pull because the package manager exposes a public “apk path” through the pm path command.
adb devices
You should see your device’s serial number.
adb shell pm list packages | grep -i partial‑name
Example: to locate the Facebook app:
adb shell pm list packages | grep -i facebook
Output: package:com.facebook.katana
adb shell pm path com.facebook.katana
Expected output: package:/data/app/com.facebook.katana-1/base.apk
adb pull /data/app/com.facebook.katana-1/base.apk ./facebook.apk
The file facebook.apk now resides in your current directory.
The apksigner verify command checks both the integrity of the ZIP structure and the cryptographic signature. It also reports which signing scheme (v1‑JAR, v2‑APK, v3‑APK) the app uses.
apksigner verify --verbose facebook.apk
Verifies
Verified using v2 scheme (APK Signature Scheme v2)
Verified using v1 scheme (JAR Signature)
The presence of both v1 and v2 indicates backward compatibility.
DOES NOT VERIFY
ERROR: No signatures found in the APK.
ERROR: Failed to verify the APK.
In that case, do not install the APK – it may have been tampered with.
apksigner to print the certificate’s SHA‑256 fingerprint, which you can compare against the developer’s published fingerprint.
apksigner verify --print-certs facebook.apk
The output includes SHA-256 digest lines you can copy.Most reputable developers publish the SHA‑256 fingerprint of their signing certificate on their website or in the Play Store listing (under “App details”). If you can’t find it, you can retrieve the fingerprint directly from the Play Store APK using the same method, then compare the two values.
apksigner verify --print-certs official.apk and note the SHA-256 digest value.Signature verification ensures the APK is signed, but it does not guarantee the file wasn’t corrupted during transfer. Compute a checksum and compare it with the one published by the developer (if available).
# Windows PowerShell
Get-FileHash -Algorithm SHA256 .\facebook.apk
# macOS / Linux
shasum -a 256 facebook.apk
Match the hash string against the developer’s published value.
adb shell pm list packages -f to see the full list with paths.apksigner still reports. Ensure you are using the --verbose flag..apk files), you need to verify each part individually.
# Example for a split APK set
apksigner verify --verbose base.apk
apksigner verify --verbose split_config.en.apk
Once all checks pass, you can install the APK with:
adb install -r facebook.apk
The -r flag replaces any existing version without losing data.
Verifying an APK’s signature is a small extra step that dramatically reduces the risk of installing tampered software. By pulling the APK with ADB, using the official apksigner tool, and comparing the certificate fingerprint, you gain confidence that the app truly comes from its claimed developer. The same workflow works for any Android app – whether it’s a game, a productivity tool, or a custom ROM component.
Keep this guide bookmarked; the next time you receive an APK from a friend, a forum, or a backup, you’ll have a reliable, no‑root method to confirm its authenticity before it ever touches your device.









