Apk (file format) explained

APK
Genre:Package format
Extended From:JAR

The Android Package with the file extension apk[1] is the file format used by the Android operating system and a number of other Android-based operating systems for distribution and installation of mobile apps, mobile games and middleware. A file using this format can be built from source code written in either Java or Kotlin.

APK files can be generated and signed from Android App Bundles.[2]

Overview

APK is analogous to other software packages such as APPX in Microsoft Windows, APP for HarmonyOS or a Debian package in Debian-based operating systems. To make an APK file, a program for Android is first compiled using a tool such as Android Studio[3] or Visual Studio and then all of its parts are packaged into one container file. An APK file contains all of a program's code (such as .dex files), resources, assets, certificates, and manifest file. As is the case with many file formats, APK files can have any desired name but, for the system to recognize them, the .apk filename suffix may be necessary.[4]

Most Android implementations allow users to manually install APK files (sideloading) only after they turn on an "Unknown Sources" setting that allows installation from sources other than trusted ones such as Google Play. This may be done for many reasons, such as during the development of apps, to install apps not available on the store, or to install an older version of an app in the Play Store.[5]

Use on other operating systems

The QNX-based BlackBerry 10 included an Android runtime environment; initially, apps were required to be packaged in the operating system's native format, and installed via the BlackBerry World app store or sideloading.[6] Beginning on BlackBerry 10.2.1, the operating system added support for sideloading APK files directly.[7] [8]

At Build 2015, Microsoft announced an Android runtime environment for Windows 10 Mobile codenamed "Astoria" (later renamed Windows Bridge for Android), which would allow Android apps to run in an emulated environment with minimal changes, and have access to Microsoft platform APIs such as Bing Maps and Xbox Live as nearly drop-in replacements for equivalent Google Mobile Services. Google Mobile Services and certain core APIs would not be available, and apps with "deep integration into background tasks" were said to poorly support the environment.[9] [10] On February 25, 2016, after already having delayed it in November 2015,[11] [12] Microsoft announced that Windows Bridge for Android would be shelved, in favor of focusing on Windows Bridge for iOS (a native implementation of the iOS Objective-C APIs, which allows Xcode projects to be converted to Visual Studio projects targeting Windows platforms) and cross-platform development using the C# language instead.[13] [14] Portions of Astoria were used as a basis for Windows Subsystem for Linux (WSL) on the PC version of Windows 10.[15]

On August 9, 2019, HarmonyOS came with APK compatibility via AOSP base with Linux kernel on HarmonyOS 1.0 for TVs and also June 2, 2021, HarmonyOS 2.0 version expanded to smartphones and tablets until Galaxy Edition version under HarmonyOS NEXT system for the next iterative HarmonyOS 5 beta to commercial version, starting in November 26, 2024 stable, officially dropping APK support.[16] [17] [18]

In June 2021, Microsoft announced the "Windows Subsystem for Android" (WSA), an AOSP-based layer for sideloading Android apps on Windows 11. The software utilized a runtime compiler developed by Intel, and apps could be sideloaded, published via Microsoft Store, or obtained via an Amazon Appstore client.[19] [20] [21] Microsoft deprecated and discontinued WSA in March 2025.[22]

Package contents

An APK file is a ZIP archive that usually contains the following files and directories:

the Manifest file

Created-By: 1.0 (Android)SHA1-Digest-Manifest: wxqnEAI0UA5nO5QJ8CGMwjkGGWE=...Name: res/layout/exchange_component_back_bottom.xmlSHA1-Digest: eACjMjESj7Zkf0cBFTZ0nqWrt7w=Name: res/drawable-hdpi/icon.pngSHA1-Digest: DGEqylP8W0n0iV/ZzBx3MW0WGCA=

See also

Further reading

Notes and References

  1. Web site: Application Fundamentals. Android Developers. en. 2018-12-03. dmy-all. 2020-11-21. https://web.archive.org/web/20201121155829/https://developer.android.com/guide/components/fundamentals. live.
  2. Web site: Peters . Jay . 2021-06-30 . Google is moving away from APKs on the Play Store . 2021-08-15 . The Verge . dmy-all . 2021-08-04 . https://web.archive.org/web/20210804045536/https://www.theverge.com/2021/6/30/22557390/google-apk-app-bundles-package-format-play-store . live .
  3. Web site: Application Studio. Android Developers. 2020-02-22. 2021-09-12. https://web.archive.org/web/20210912113844/https://developer.android.com/studio/intro. live.
  4. Web site: Inside the Android Application Framework . 2008 . Google Sites . video . 2008-10-22 . 2011-12-24 . https://web.archive.org/web/20111224184753/http://sites.google.com/site/io/inside-the-android-application-framework . live .
  5. Web site: Unknown Sources: Everything you need to know! . Android Central . 27 July 2018 . 4 March 2020 . 1 September 2021 . https://web.archive.org/web/20210901234654/https://www.androidcentral.com/unknown-sources . live .
  6. Web site: Segan . Sascha . January 31, 2013 . How BlackBerry 10 Runs 28,000 Android Apps Without a Back Button . live . https://web.archive.org/web/20230605031631/https://www.pcmag.com/article2/0,2817,2414928,00.asp . 5 June 2023 . 18 June 2014 . PC Magazine.
  7. Web site: Kastrenakes . Jacob . June 18, 2014 . BlackBerry will bring thousands of apps from Amazon's store to its phones . live . https://web.archive.org/web/20230604113425/https://www.theverge.com/2014/6/18/5820472/blackberry-phones-getting-amazon-appstore-apps-in-bb10-3 . June 4, 2023 . June 18, 2014 . The Verge.
  8. Web site: 2014-01-28 . There was no mention of Android app support in the official BlackBerry 10.2.1 announcement, but it's there! . 2025-11-22 . CrackBerry . en.
  9. Web site: How will Android support work in Windows 10 for Phones?. TechRadar Pro. May 22, 2015. https://web.archive.org/web/20150519175925/http://www.techradar.com/us/news/software/applications/how-will-android-support-work-in-windows-10-mobile--1293295. May 19, 2015. dead.
  10. Web site: Microsoft brings Android, iOS apps to Windows 10. Ars Technica. April 29, 2015. April 30, 2015. July 8, 2017. https://web.archive.org/web/20170708094358/https://arstechnica.com/information-technology/2015/04/microsoft-brings-android-ios-apps-to-windows-10/. live.
  11. Web site: Microsoft might not bring Android apps to Windows after all. The Verge. November 16, 2015. Vox Media. November 16, 2015. November 17, 2015. https://web.archive.org/web/20151117140442/http://www.theverge.com/2015/11/16/9742338/microsoft-android-apps-on-windows-on-hold. live.
  12. Web site: Microsoft presses pause on tool for porting Android apps to Windows 10. CNET. CBS Interactive. Katie. Collins. November 16, 2015. May 26, 2022. July 9, 2017. https://web.archive.org/web/20170709151838/https://www.cnet.com/news/microsoft-presses-pause-on-tool-for-porting-android-apps-to-windows-10/. live.
  13. Web site: Microsoft confirms: Android-on-Windows Astoria tech is gone. Ars Technica. February 25, 2016. Conde Nast. February 25, 2016. February 25, 2016. https://web.archive.org/web/20160225215742/http://arstechnica.com/information-technology/2016/02/microsoft-confirms-android-on-windows-astoria-tech-is-gone/. live.
  14. Web site: An Update on the Developer Opportunity and Windows 10. Building Apps for Windows blog. February 25, 2016. Microsoft. February 25, 2016. February 26, 2016. https://web.archive.org/web/20160226023120/https://blogs.windows.com/buildingapps/2016/02/25/an-update-on-the-developer-opportunity-and-windows-10/. live.
  15. Web site: Bright. Peter. Why Microsoft needed to make Windows run Linux software. Ars Technica. Condé Nast. April 6, 2016. May 26, 2022. April 6, 2016. https://web.archive.org/web/20160406003006/https://arstechnica.com/information-technology/2016/04/why-microsoft-needed-to-make-windows-run-linux-software/. live.
  16. Web site: 2021-06-11 . Google apps still working after upgrading to HarmonyOS from EMUI, don't need to panic . 2025-05-26 . Huawei . en-US . 2025-06-07 . https://web.archive.org/web/20250607151514/https://consumer.huawei.com/ph/community/details/topicId-132379/ . live .
  17. Web site: Matsui . Emiko . HarmonyOS NEXT Galaxy will officially meet users in Spring: Huawei . HC Newsroom . 7 February 2024 . 12 February 2024 . 14 September 2024 . https://web.archive.org/web/20240914141526/https://www.huaweicentral.com/harmonyos-next-galaxy-will-officially-meet-users-in-spring-huawei/ . live .
  18. Web site: Matsui . Emiko . 2024-04-11 . Huawei to launch HarmonyOS NEXT beta at HDC 2024 event in June . 2024-04-11 . Huawei Central . en-US . 2024-05-29 . https://web.archive.org/web/20240529175130/https://www.huaweicentral.com/huawei-to-launch-harmonyos-next-beta-at-hdc-2024-event-in-june/ . live .
  19. Web site: Jordan . Novet . Leswing . Kif . Haselton . Todd . June 24, 2021 . Microsoft Windows 11 will support Android apps . live . https://web.archive.org/web/20210624143625/https://www.cnbc.com/2021/06/24/microsoft-windows-11-event-live-updates.html . June 24, 2021 . June 24, 2021 . CNBC.
  20. News: Warren . Tom . June 24, 2021 . Microsoft is bringing Android apps to Windows 11 with Amazon's Appstore . live . https://web.archive.org/web/20210624153856/https://www.theverge.com/2021/6/24/22548428/microsoft-windows-11-android-apps-support-amazon-store . June 24, 2021 . June 24, 2021 . The Verge.
  21. Web site: Gartenberg . Chaim . June 24, 2021 . Windows 11's Intel-powered Android apps will run on AMD and Arm processors, too . live . https://web.archive.org/web/20210624204301/https://www.theverge.com/2021/6/24/22549303/windows-11-intel-bridge-android-apps-amd-arm-processors . June 24, 2021 . June 24, 2021 . The Verge.
  22. Web site: Warren . Tom . Microsoft to end its Android apps on Windows 11 subsystem in 2025 . The Verge . 5 March 2024 . 5 March 2024 . 5 May 2024 . https://web.archive.org/web/20240505220310/https://www.theverge.com/2024/3/5/24091370/microsoft-windows-11-android-apps-end-of-support . live .
  23. Web site: ABI Management Android Developers. developer.android.com. 16 June 2018. 31 May 2019. https://web.archive.org/web/20190531122811/https://developer.android.com/ndk/guides/abis.html. live.
  24. Web site: Android ABIs Android NDK. 2020-08-14. Android Developers. en. Note: Historically the NDK supported ARMv5 (armeabi), and 32-bit and 64-bit MIPS, but support for these ABIs was removed in NDK r17.. 2019-04-08. https://web.archive.org/web/20190408105838/https://developer.android.com/ndk/guides/abis. live.
  25. Web site: Dan. Albert. Sep 5, 2018. Changelog r17. 2020-08-14. GitHub. en. Support for ARMv5 (armeabi), MIPS, and MIPS64 has been removed. Attempting to build any of these ABIs will result in an error.. 2020-08-28. https://web.archive.org/web/20200828032714/https://github.com/android/ndk. live.