🌐
GitHub
github.com › kivy › python-for-android
GitHub - kivy/python-for-android: Turn your Python application into an Android APK · GitHub
Turn your Python application into an Android APK. Contribute to kivy/python-for-android development by creating an account on GitHub.
Starred by 8.9K users
Forked by 2K users
Languages   Python 75.1% | Java 13.9% | C 5.4% | Makefile 1.4% | kvlang 1.4% | Cython 1.2%
🌐
GitHub
github.com › topics › python-for-android
python-for-android · GitHub Topics · GitHub
Python game for android, developed using python-pygame and built using python-for-android.
🌐
GitHub
github.com › kuri65536 › python-for-android
GitHub - kuri65536/python-for-android: Automatically exported from code.google.com/p/python-for-android
Automatically exported from code.google.com/p/python-for-android - kuri65536/python-for-android
Starred by 254 users
Forked by 105 users
Languages   Python 69.7% | HTML 23.7% | Java 2.8% | C 2.6% | OpenEdge ABL 0.5% | Makefile 0.3% | Python 69.7% | HTML 23.7% | Java 2.8% | C 2.6% | OpenEdge ABL 0.5% | Makefile 0.3%
🌐
GitHub
github.com › qpython-android › qpython
GitHub - qpython-android/qpython: QPython is an Android Python engine primarily designed for Python and AI learners. It offers a range of impressive features to enhance Python programming experience.
QPython is the Python engine for android. It contains some amazing features such as Python interpreter, runtime environment, editor and QPYI and integrated SL4A. It makes it easy for you to use Python on Android.
Starred by 1.2K users
Forked by 206 users
Languages   Java 97.6% | AIDL 1.2% | C++ 0.6% | C 0.2% | CSS 0.2% | HTML 0.1% | Java 97.6% | AIDL 1.2% | C++ 0.6% | C 0.2% | CSS 0.2% | HTML 0.1%
🌐
Reddit
reddit.com › r/learnpython › running python on android phone
r/learnpython on Reddit: Running Python on Android phone
December 14, 2024 -

First: As I have seen some a bit hostile responses to questions like this here so please tell me to fuck off if I'm in wrong. :)

I want to be able to run Python programs on my Android phone. The main usage will be file management and editing of text files etc. Maybe use it to control or monitor activities on the phone. I'm not asking for anything about coding in Python, maybe except Android specific things. (I'm not familiar with coding with Python but will learn that by other means).

So in short: what to install, how to install (in short - I have not any experience in installing these kind of software on my phone) and elementary pitfalls.

(Background: have been programming professionally since 1979 and are still doing that. Mainly mainframe.)

Thomas

🌐
GitHub
github.com › yan12125 › python3-android
GitHub - yan12125/python3-android: Python 3 cross-compilation tools for Android. · GitHub
Python 3 cross-compilation tools for Android. Contribute to yan12125/python3-android development by creating an account on GitHub.
Starred by 92 users
Forked by 34 users
Languages   Python 84.3% | Shell 15.7%
🌐
GitHub
github.com › Mrakorez › py2droid
GitHub - Mrakorez/py2droid: Magisk/KernelSU/APatch module to install Python 3 on Android. · GitHub
Py2Droid is CPython 3 compiled for Android and packaged as a Magisk module. It provides system-level Python access without requiring Termux or other userland environments.
Starred by 47 users
Forked by 5 users
Languages   Python 82.4% | Shell 17.6%
🌐
GitHub
github.com › PsiCodes › ktxpy
GitHub - PsiCodes/ktxpy: Python Compiler/ide For Android with Material3 · GitHub
Python Compiler/ide For Android with Material3. Contribute to PsiCodes/ktxpy development by creating an account on GitHub.
Starred by 95 users
Forked by 21 users
Languages   Kotlin
Find elsewhere
🌐
GitHub
github.com › TrellixVulnTeam › python-for-android_SCYG
GitHub - TrellixVulnTeam/python-for-android_SCYG: Turn your Python application into an Android APK · GitHub
Turn your Python application into an Android APK. Contribute to TrellixVulnTeam/python-for-android_SCYG development by creating an account on GitHub.
Author   TrellixVulnTeam
Top answer
1 of 4
186

To answer your first question: yes it is feasible to develop an android application in pure python, in order to achieve this I suggest you use BeeWare, which is just a suite of python tools, that work together very well and they enable you to develop platform native applications in python.

checkout this video by the creator of BeeWare that perfectly explains and demonstrates it's application

How it works

Android's preferred language of implementation is Java - so if you want to write an Android application in Python, you need to have a way to run your Python code on a Java Virtual Machine. This is what VOC does. VOC is a transpiler - it takes Python source code, compiles it to CPython Bytecode, and then transpiles that bytecode into Java-compatible bytecode. The end result is that your Python source code files are compiled directly to a Java .class file, which can be packaged into an Android application.

VOC also allows you to access native Java objects as if they were Python objects, implement Java interfaces with Python classes, and subclass Java classes with Python classes. Using this, you can write an Android application directly against the native Android APIs.

Once you've written your native Android application, you can use Briefcase to package your Python code as an Android application.

Briefcase is a tool for converting a Python project into a standalone native application. You can package projects for:

  • Mac
  • Windows
  • Linux
  • iPhone/iPad
  • Android
  • AppleTV
  • tvOS.

You can check This native Android Tic Tac Toe app written in Python, using the BeeWare suite. on GitHub

in addition to the BeeWare tools, you'll need to have a JDK and Android SDK installed to test run your application.

and to answer your second question: a good environment can be anything you are comfortable with be it a text editor and a command line, or an IDE, if you're looking for a good python IDE I would suggest you try Pycharm, it has a community edition which is free, and it has a similar environment as android studio, due to to the fact that were made by the same company.

I hope this has been helpful

2 of 4
20

You could try BeeWare - as described on their website:

Write your apps in Python and release them on iOS, Android, Windows, MacOS, Linux, Web, and tvOS using rich, native user interfaces. One codebase. Multiple apps.

Gives you want you want now to write Android Apps in Python, plus has the advantage that you won't need to learn yet another framework in future if you end up also wanting to do something on one of the other listed platforms.

Here's the Tutorial for Android Apps.

🌐
YouTube
youtube.com › ahmad cooper
[Python to APK] - Convert Python to Android with GitHub 2022 - YouTube
[Disclosure]Working as of 01/10/2022. May not work in the future.I'm not responsible if your computer blows up etc. follow the tutorial at your own risk. Thi...
Published   October 1, 2022
Views   10K
🌐
GitHub
github.com › clevermindgames › python-for-android-kivmob27
GitHub - clevermindgames/python-for-android-kivmob27: Fork of python-for-android to support Admob ads (Banners, Interstitials and Reward videos) for API 27 · GitHub
Fork of python-for-android to support Admob ads (Banners, Interstitials and Reward videos) for API 27 - clevermindgames/python-for-android-kivmob27
Author   clevermindgames
🌐
GitHub
github.com › kivy › python-for-android › releases
Releases · kivy/python-for-android
Turn your Python application into an Android APK. Contribute to kivy/python-for-android development by creating an account on GitHub.
Author   kivy
🌐
GitHub
github.com › topics › pythonforandroid
Build software better, together
In app review integration for kivy on android. android python kivy pythonforandroid in-app-review
🌐
GitHub
github.com › topics › android-python
android-python · GitHub Topics · GitHub
android game primer python game-development game-2d python3 pygame mouse-tracking python-for-android android-python pygame-gui pygame-games python-game-development python-games python-g plyer-module
🌐
GitHub
github.com › topics › android-application
android-application · GitHub Topics · GitHub
Localizr is a Tool that handles and automates the generation of localization files for IOS and Android so there will be only one source of truth for all of your localization strings. android i18n ios mobile translation localization dsl fastlane actions android-application locale ... A tool capable of bypassing easy root detection mechanisms by patching applications automatically (without frida). apk android-application owasp mobile-security mstg masvs ... A python script that helps you create strings.xml for all languages in different hierarchical folder(using Google Translation API)
🌐
GitHub
github.com › Android-for-Python › Camera4Kivy
GitHub - Android-for-Python/Camera4Kivy: Yet Another Camera for Kivy
Yet Another Camera for Kivy. Contribute to Android-for-Python/Camera4Kivy development by creating an account on GitHub.
Starred by 56 users
Forked by 23 users
Languages   Python 100.0% | Python 100.0%