# kivy/python-for-android

Turn your Python application into an Android APK

Repository: https://github.com/kivy/python-for-android
Canonical: https://ross.abutalabs.com/products/python-for-android
Homepage: https://python-for-android.readthedocs.io
Language: Python
License: MIT
License Family: permissive
Topics: python, android, apk, packaging, kivy
Last push: 2026-08-26T05:40:24+00:00

## Health v2 (maintenance only)
Score: 82/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 99, release rhythm 51, longevity 100
- inputs: {"age_days": 5392, "days_push": 7, "days_rel": 115, "gap_med": null, "n_releases_24m": 1}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 8910, forks 2038 (observed 2026-08-28T04:10:26.242316+00:00)

## What it is
python-for-android (p4a) is a command-line development tool that cross-compiles the Python interpreter and packages Python applications into Android binaries (APK, AAB, AAR). It supports Kivy, PySDL2/PySDL3, and WebView bootstraps, with recipes for cross-compiling C-extension dependencies like numpy.

## Use cases
- package a python app as an android apk
- build an aab for google play from python code
- cross-compile python and numpy for android
- turn my kivy app into an android app
- run a python web server inside a webview on android
- create a reusable android library (aar) from python code

## When to choose
- you want to ship a Python (especially Kivy) app to Android without rewriting it in Java/Kotlin
- you need APK/AAB/AAR output with multi-architecture support
- your dependencies are pure Python or covered by existing recipes

## When to avoid
- you need native Android UI performance or deep platform API integration
- your app depends on C extensions lacking a recipe and you cannot write one
- you are targeting iOS or desktop platforms

## Facets
- artifact type: cli-tool
- maturity: active
- function: build-tool, compiler, developer-tools
- domain: mobile-development, cross-platform, developer-tools
- platform: python, cli
- tags: apk-packaging, aab, aar, cross-compilation, kivy, pysdl2, webview-bootstrap, recipes, android, linux, macos

## Member repositories
- kivy/python-for-android (main) score 82

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:10:26.242316+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T17:24:43.091509+00:00, confidence not recorded.
  - readme: https://github.com/kivy/python-for-android (fetched 2026-08-28T04:10:26.242316+00:00, sha bbe1546993f4)
  - homepage: https://python-for-android.readthedocs.io (fetched 2026-08-29T08:24:52.046736+00:00, sha d18073b80deb)
  - registry_pypi: https://pypi.org/pypi/python-for-android/json (fetched 2026-08-29T08:24:52.063955+00:00, sha 855bc469076d)
- Data as of 2026-08-30T08:39:29.467469+00:00.
