· Droidwatch Security Research team · 10 min read · Static Analysis Deep-Dives APK analysis APK triage Mobile security
🌐 Leer en español → 🌐 Ler em português →

How to Check if an APK Is Safe Before Installing It

Six checks to run on an APK file before installing it: source, package name, hash reputation, signing certificate, permissions and a static analysis report.

How to Check if an APK Is Safe Before Installing It

An APK received by message, downloaded from a website or offered by a third-party store can be checked before it is installed. Six checks, in order of cost, answer most cases: where the file came from, what its package name claims, whether its hash is already known, who signed it, what permissions it requests, and what a static analysis of the package shows. None of them requires installing the app or running it; checks 3 and 4 need the file on a computer.

The checks do not prove that an app is harmless. They establish whether the file is what it claims to be and what it is capable of doing, which is usually enough to make an informed installation decision.

Why APKs from outside Google Play need checking

Android lets users install apps from sources other than Google Play. Since Android 8.0, permission to install unknown apps is granted per source: the browser, a file manager or a messaging app each has to be allowed separately. Once that permission is granted, the package installer accepts any APK the source delivers.

Android banking malware and stalkerware commonly reach devices this way. The documented campaigns in Latin America — fake bank authentication apps sent by WhatsApp or SMS, fake Google Play pages behind streaming lures, ads posing as Netflix — each rely on the user installing an APK from outside Play, as set out in the Android banking malware landscape for Latin America.

Google Play Protect adds a layer. Google announced in October 2023 that Play Protect recommends a real-time, code-level scan when a user tries to install an app it does not recognize from outside Play, starting in India and expanding to other regions. Play Protect is a useful net, not a substitute for the checks below.

Check 1: where the file came from

The source is the cheapest signal and often the decisive one.

Source Risk
Google Play, or the official store of the device manufacturer Lowest; apps are reviewed, though not infallibly
The developer's own website, reached by typing its address Moderate; depends on the developer
A link received by SMS, WhatsApp, email or social media High, especially if it claims to come from a bank, courier or government agency
A third-party APK site or "mod" store High; repackaged builds are common
An ad, pop-up or "update required" page in a browser Very high

A bank, a courier or a tax authority asking a customer to install an app from a link is a recurring pattern in mobile fraud. Banks distribute their apps through official stores.

Check 2: what the package name claims

Every Android app has a package name in reverse-DNS form, such as com.whatsapp. It is chosen by the developer and cannot change once the app is published, but anyone can build an APK with any package name, so it is a claim, not proof of identity.

Two rules catch many impostors:

A package that imitates a system name and does not exist on Play is a reason to continue checking, not to conclude. The full procedure is in how to identify an unknown Android package name.

Check 3: whether the hash is already known

A file's SHA-256 hash identifies it exactly. On a computer it is computed with sha256sum file.apk on Linux, shasum -a 256 file.apk on macOS or Get-FileHash file.apk in PowerShell.

Searching the hash on VirusTotal shows whether any of its more than 70 antivirus engines has seen and classified the file. A search by hash does not upload the file. Uploading it does, and VirusTotal's documentation states that the contents of submitted files may be shared with its premium customers, so a file that may contain personal or confidential data should be searched, not uploaded.

A known detection is a strong signal. A hash that VirusTotal has never seen means only that nobody has submitted the file; zero detections on a recent file mean only that no engine has classified it yet. The trade-offs between reputation services and analysis tools are covered in the comparison of APK analysis tools.

Check 4: who signed it

Every APK is signed with a certificate controlled by its developer. A repackaged app — a legitimate app modified to add malicious code — cannot carry the original developer's signature, because the private key is not available to whoever modified it.

With the Android SDK build tools installed, the certificate is printed with:

apksigner verify --print-certs file.apk

The output includes the certificate's subject and its SHA-256 fingerprint. Three readings matter:

Comparing against the official app's certificate requires knowing it. A static analysis report checks the package against Google Play and shows the full certificate chain, which makes the comparison easier.

Check 5: what it asks to do

The manifest declares the permissions and components the app uses. With the Android SDK build tools installed, the requested permissions are listed with aapt2 dump permissions file.apk. Accessibility services, notification listeners and device administrators appear as declared services or receivers protected by BIND_* permissions rather than as ordinary permission requests.

Some combinations have no ordinary explanation in the type of app the file claims to be.

Request What it allows Warning sign when
Accessibility service Reading the screen and acting on other apps The app is not an accessibility tool
Display over other apps Drawing windows over other apps Combined with accessibility in a non-utility app
READ_SMS, RECEIVE_SMS Reading messages, including one-time codes The app is not a messaging app
Notification listener Reading notification content The app has no reason to read other apps' notifications
Device administrator Locking or wiping the device; an active admin app must be deactivated before it can be uninstalled The app is not an enterprise or security tool
REQUEST_INSTALL_PACKAGES Installing other apps The app is not a store or updater

A flashlight, a "security update" or a delivery tracking app that requests accessibility, SMS access and device administration describes the capability set of a banking trojan. How Android banking trojans work explains how these capabilities combine.

Android does not list these requests at installation. Dangerous permissions are requested when the app first uses them, and accessibility, overlay, notification access and device administration are switched on in Settings after installing. Reading the manifest before installing is the only point at which the full set is visible.

Check 6: a static analysis report

Checks 2, 4 and 5 can each be done by hand. A static analysis service runs them together, plus several that are impractical by hand, and returns a report that can be kept or shared. The source of the file and its reputation on VirusTotal remain separate checks.

Droidwatch accepts APK, AAB, XAPK and DEX files, as well as iOS IPA files, and analyzes them without executing them. For an Android package, the report covers the package identity and its verification against Google Play, the full signing certificate, permissions and components, DEX bytecode and obfuscation, native libraries, third-party SDKs, network indicators, and a mapping to MITRE ATT&CK Mobile techniques. Risk is scored from 0 to 100, where higher is worse: 65 or more is Malicious, 40-64 High Risk, 20-39 Suspicious and below 20 Benign. A 50 MB APK takes two to five minutes.

Three analyses a day are available without an account, for files up to 150 MB, and five a day with a free account. Submissions are private by default. The structure of the report is described in analyze an APK online: inside a Droidwatch report.

Reading the result

Outcome Typical evidence Decision
Matches the official app Play page exists, certificate matches, permissions fit the function Install from the official store rather than from the file
Unknown but coherent No detections, consistent certificate, permissions fit the claimed function Acceptable risk if the source is trustworthy
Repackaged Same name as a known app, different certificate Do not install; report it to the original developer
Malicious capability set Accessibility plus SMS or overlay in an app with no reason for them, system-like name, sent by link Do not install; delete the file

Limits of pre-installation checks

Static analysis shows what the code in the package is capable of doing; packing, obfuscation and code loaded after installation limit what it can see. Some malware downloads its malicious stage after installation, so the first file looks benign; a dropper is identified by its ability to install other apps and load code dynamically, not by its visible features. And no check replaces the most important one: an app that arrives through an unexpected link, with urgency and a reason to bypass the official store, should not be installed at all.

Frequently asked questions

How can I tell if an APK is safe? Check where it came from, whether its package name matches a real app on Google Play, whether its hash has known detections, who signed it, and whether its permissions fit its function. A static analysis service examines the package itself — identity, certificate, permissions and code — and scores the result; where the file came from still has to be judged separately. None of these checks proves an app is harmless.

Is it safe to install APKs from outside Google Play? It can be, for apps from trusted developers distributed through their own sites. APKs received through links in messages, ads or third-party sites are the usual delivery route for Android malware and should be checked before installing.

Can an APK be scanned without installing it? Yes. A hash lookup, a certificate check and a static analysis report all work on the file itself. Droidwatch analyzes APK files without executing them and allows three analyses a day without an account.

Does Google Play Protect scan apps from outside Play? Google announced in October 2023 that Play Protect recommends a real-time code-level scan for unrecognized apps installed from outside Play, starting in India and expanding to other regions. It should be kept on, but it does not replace checking the file.

What permissions are a red flag in an APK? The accessibility service, display over other apps, SMS access, notification access and device administration, when the app has no functional reason for them. The combination matters more than any single permission.

Threat Research

Droidwatch's research team analyzes Android & iOS malware — banking trojans, spyware, droppers and overlay kits — and writes up the static and dynamic signals that give them away. Every post is grounded in real platform output.

Analyze your first app free — drag an APK or iOS .ipa onto the homepage for a full static report in a few minutes. Get started free