apksigner
Sign and verify Android APK files
TLDR
Sign an APK
SYNOPSIS
apksigner command [options] apk
DESCRIPTION
apksigner is the official Android SDK tool for signing APK files. It supports multiple signature schemes (v1/JAR, v2, v3, v4) and can sign aligned APKs produced by zipalign.
The tool ensures APKs meet Android's signing requirements for installation and updates, with newer schemes providing better security and verification speed.
PARAMETERS
sign
Sign an APKverify
Verify APK signatures--ks file
Keystore file--ks-key-alias alias
Key alias in keystore--ks-pass pass
Keystore password (pass: or file:)--key-pass pass
Key password--out file
Signed APK output path--v1-signing-enabled bool
Enable JAR signing (v1)--v2-signing-enabled bool
Enable APK Signature Scheme v2--v3-signing-enabled bool
Enable APK Signature Scheme v3--verbose
Verbose output--print-certs
Print certificate details
CAVEATS
APK must be zipaligned before signing with v2+. v1-only signing is deprecated for Android 11+. Key rotation requires v3 signing. Private key security is critical.
HISTORY
apksigner was introduced in Android SDK Build Tools 24.0.3 (2016) alongside APK Signature Scheme v2, replacing jarsigner as the recommended signing tool.
