Python Mobile Development: When And Why to Build Your App With Python?
Oct 26, 20206 min read
Senior full stack developer and CTO at Ideamotive.
Do you have an awesome idea of a mobile app, but don’t know what language can fit for its realization?
Today we will take a closer look at a bit of an unorthodox approach: we will overview the concept of Python mobile development.
Read further, and you will get to know what are the peculiarities of mobile apps development in Python and what types of mobile products it is appropriate for. Also, we will give you some useful tips on how to develop mobile apps in Python and the successful examples of the products written in this programming language.
Can Python be used for mobile apps development?
Python is a rather universal programming language which is appropriate for solving a wide range of tasks. And everybody knows that it is used in such spheres as web-development, data science, and different processes automation.
But can Python be used for mobile apps?
The answer is: yes, you can. It has become possible due to the Kivy framework released in 2011.
It allows cross-platform development of the apps for PC and for mobile devices. This framework uses the custom set of UI instruments that engage the same control elements on different platforms.
But is it real to develop native mobile apps in Python? Yes, it is. Another framework, BeeWare, will help you with this.
It uses the set of instruments that engage the native control elements of each platform. In BeeWare, buttons, checkboxes, and other elements provided by the system which the app is developed for will play the role of UI controllers. That’s why the product will look like 100% native while being used on the platform you’ve built it for. So, you can create native mobile apps for Android or for iOS in Python with the help of BeeWare framework.
What types of mobile products are good for Python?
Python mobile development was not popular previously. But things have changed with the appearance of different Python GUI frameworks. And currently, this programming language is widely used in mobile apps development.
Python is rather versatile. It can be used for building various apps: starting with web-browsers and ending with simple games.
One more powerful advantage is being cross-platform. So, it’s possible to develop both Android and iOS apps in Python.
What should you take into account while building mobile apps in Python?
When you have decided to build a mobile app with Python, you need a GUI first. There are two most popular frameworks – Kivy and BeeWare that we have mentioned earlier. However, those are not the only ones to be used during the development process. What else you can use for Python mobile development:
What are those frameworks for? Python-for-Android is a tool allowing Python to work with Android. Its main function is to create a project folder including all necessary tools to launch the mobile app. This folder comprises Kivy and various libraries such as Pygame, SDL, and others. This folder includes a Java loader, which is a kind of intermediate between Kivy and OS. Later you are going to add your own scripts and compile the application using Android NDK.
PyJNIus is a framework designed to provide interaction between Python and Android API. By using this API you can get information from various parts of the mobile device including vibration, pause, restart, and many others.
The main disadvantage of this framework is that it requires strong knowledge of Android API and makes an abundant code. However, it is to mention that PyJNIus Java competitor looks the same.
Plyer was designed to solve this problem. This project aims to create a simple Python interface including functions that can be found in most modern mobile platforms. The code that you are going to write using Plyer will be executed on all supported platforms including Android, iOS, Linux, Windows, and OS X. As for iOS, there is another framework that you can use – PyOBJus.
What else should you remember if you want to develop mobile app using Python? This language has several disadvantages. Here they are:
Dynamic scope. To evaluate the expression, the interpreter searches for the variable in the current block and then in all functions. The problem is that each expression should be verified in all possible contexts.
Lambda functions are limited in Python. They can be expressions, not operators.
Python uses an interpreter and not a compiler. Any error that you have in your app will be found out only during the execution. This leads to speed slowdown and the necessity to create various tests.
What resources do you need to develop mobile app using Python?
If you are going to build an app by yourself, the main resource you need is time. How long will it take to develop anything in Python? Of course, it depends on the difficulty of the idea and the level of your programming skills. But on average, it takes from 3 months to create a mobile app in any language by professional developers. If you are only studying, get ready to work longer. And, finally, what to do if you haven’t mastered Python anymore, but already interested in the issue of developing mobile apps in this language? Then, firstly, it will take you at least 2 months to learn it, as CareerKarma says.
If you are going to manage the project but not to be engaged in development then you need to know how much time different stages take:
Creating a brief for the developers— 7-14 days.
Looking for the appropriate programmers and discussing the idea with them — approximately a month.
Design development — 1,5-3 months.
Development of the app — 3 months.
Release on App store — up to 14 days.
So, all the processes will take up to 8 months.
If you are not going to build an app by yourself, then the second resource you need for Python mobile development is money. The final cost of the project will depend on:
The difficulty. The simpler the task is the fewer programmers you need to engage and the cheaper professionals you can hire.
The region of living. Of course, the cost of work of an American developer will be higher than the one of an Indian or Russian one. Actually, you can solve this problem by hiring a remote specialist from the country with lower salaries. But then you will have to overcome the language barrier and the impossibility to meet live in the office for discussing the details about the project.
Here is the statistics on the average Python developers’ monthly rates in different countries for you to understand what the approximate needed budget is:
Multiply the sum by the number of months you will need the developer to work, and you will get the figure of the needed budget. For example, if you hire a junior US programmer for building an easy app for 3 months, it will take you $21600. Or if you engage a middle Ukrainian specialist in the difficult 6-months project, you will have to spend $13800.
Also, we haven’t included the salary of a designer. If you need this specialist, be ready to add some extra money to your project budget. The average salary of a designer from the USA is $68476 per year (or $5700 per month). The cost of the Poland specialist is 49533 PLN (about $13475) per year, or 4128 PLN per month (approximately $1123).
If you don’t have enough time to manage all the processes of app development by yourself, you need to hire a Scrum Master or Project Manager. It's especially useful if the team is big. The average cost of Scrum Master’s work in Poland is 120000 PLN per year (around $32644) or 10000 PLN (about $3264) per month. The average salary of such a specialist from the USA is $118353 per year (or $9863 per month). As for the Project Manager, the salary of this specialist in Poland is on average 147949 PLN (about $40267) per year, or 12329 PLN ($3355) per month. In the USA, the work of this specialist costs $99533 per year (or $8295 per month).
All the conversations to USD mentioned in the article are relevant in September 2020.
Great examples of Python mobile development results
Are you still hesitating if it’s real to realize an awesome idea in this programming language? Then look at some great examples of Python mobile development that will definitely inspire you.
This is a widely known social internet service for sharing visual content with other users. In its mobile app, one of the Python frameworks (Django) is used for working quickly with the enormous volume of information.
This is a super famous social network for sharing photos with millions of accounts. It’s hard to find a person in the whole world who is not acquainted with this app. But did you know that its backend is written in Python? This is one of the greatest examples of applying this programming language for building mobile apps.
This is a service for listening to music online without downloading it. This mobile app has a difficult backend structure. It includes several services connected to its own messaging protocol. 80% of them are developed in Python.
So, get inspired by the successful examples, take into account the tips you’ve learned from this article, and start realizing your dream project using Python!
Need an experienced Python developer?
Tell us, and we will find a talented programmer with the relevant experience and portfolio of accomplished tasks similar to yours!
Dawid is a full stack developer experienced in creating Ruby on Rails and React Native apps from naught to implementation. Technological superhero, delivering amazing solutions for our clients and helping them grow.