Build Python projects into Android APKs
Project description
APKVolt
APKVolt is a Python-based build system for packaging Python (Kivy) applications into Android APK files using precompiled runtime templates.
It is designed as a build toolchain that injects application code and assets into a structured APK template, then reconstructs and aligns the final package into a valid installable Android APK.
Overview
APKVolt works by:
- Using a precompiled Android runtime template
- Injecting Python application code and assets into the APK structure
- Updating APK metadata (manifest, resources, package info)
- Rebuilding ZIP/APK binary structure (Local Headers, Central Directory, EOCD)
- Applying Android-compatible alignment rules
- Optionally signing the final APK
Features
- APK binary parsing and reconstruction
- Template-based APK generation system
- Python/Kivy application packaging
- Native library (
.so) alignment support - APK metadata editing (package name, version, SDK levels)
- Asset injection (icons, splash screens, etc.)
- Secure APK signing (keystore-based, no CLI password exposure)
- CLI and Python library interface
- ZIP alignment system (zipalign-compatible behavior)
Installation
From source:
git clone https://github.com/euluann/apkvolt
cd apkvolt
pip install .
Requirements
Python 3.11+
Precompiled Android runtime template
Linux or Termux environment recommended
CLI Usage
Build APK
apkvolt build . \
--app-name "APKVolt App" \
--app-package mypack.package.app \
--app-version-name 0.1 \
--app-version-code 1 \
--min-sdk-version 21 \
--target-sdk-version 34 \
--icon icon.png \
--splash splash.png \
--output app.apk
If credentials are not provided, APKVolt will securely prompt for them using interactive input.
Python Usage
from apkvolt import build, apkforge, zipalign
build(
path=".",
app_name="APKVolt App",
package="mypack.package.app",
version_name="0.1",
version_code=1,
min_sdk_version=21,
target_sdk_version=34,
icon="icon.png",
splash="splash.png",
output="app.apk"
)
zipalign.align(
"app.apk",
output="app_aligned.apk",
alignment=4,
so_alignment=4096
)
apkforge.APK.signer(
apk_path,
keystore_path,
key_alias,
keystore_pass="mypass",
key_pass="mypass"
)
Architecture
APKVolt build pipeline:
-
Load precompiled APK runtime template
-
Inject Python application into APK structure
-
Apply application metadata (manifest, package info, SDK levels)
-
Insert assets (icons, splash screens, resources)
-
Rebuild APK binary structure
-
Apply alignment rules
-
Optionally sign APK
Limitations
Strong dependency on Python 3.11 runtime environment
Not a full source-to-native compiler (template-based system)
Requires careful version management of runtime APK base
Security
No password exposure via CLI arguments
Uses secure prompt input when needed
Recommended use of environment variables in automated environments
Project Goal
APKVolt aims to simplify Android application packaging for Python developers by providing a template-based build system for generating installable APKs without requiring a full native Android build toolchain.
License
MIT License. See LICENSE file for details.
Credits
See CREDITS.md for third-party assets and contributions.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file apkvolt-1.0.1.tar.gz.
File metadata
- Download URL: apkvolt-1.0.1.tar.gz
- Upload date:
- Size: 69.6 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
188119792f2a2aa067e57264a0ff109622e91f7b28b9ec1696fc7f3f5791c8e2
|
|
| MD5 |
cc955de772504dbb3274d03d59eadfbb
|
|
| BLAKE2b-256 |
035cb55dbec914c7661d4747187792aec1489cf690a57f7c89dbc1ff5eb1d1a5
|
File details
Details for the file apkvolt-1.0.1-py3-none-any.whl.
File metadata
- Download URL: apkvolt-1.0.1-py3-none-any.whl
- Upload date:
- Size: 69.6 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
072ff54d515a56056f6835b502c4155ae9898a5e37e6616052401365d170fd4d
|
|
| MD5 |
0e672f73bec02f3d49999d69bf26c19c
|
|
| BLAKE2b-256 |
01fa2889e2933131817a65fba75168f3f282247086c5cc0d5de8ca20d007ca2c
|