Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Choosing the right API Level for my android application

I currently have a application targeted at android 2.3 (api level 10), but went thinking that probably people using android 2.1/2.2 or older won't even be able to see the application in the market.

So I thought that using api level 3 would be the best to use, but I don't know if this will maybe make certain elements in my app work less good, and probably buggier, since it actually uses old android code. Is there a good way to find out which API level I should use, and also, how do I convert my application to that level?

like image 854
user717572 Avatar asked Aug 05 '11 18:08

user717572


People also ask

What Android API level should I use?

When you upload an APK, it must meet Google Play's target API level requirements. New apps must target Android 12 (API level 31) or higher; except for Wear OS apps, which must target Android 11 (API level 30) or higher.

Which Android API level should I use 2021?

Beginning in August 2021, the Google Play Console requires that new apps target API level 30 (Android 11.0) or higher. Existing apps are required to target API level 30 or higher beginning in November 2021.

How do I know my Android API level?

If you are on at least API version 4 (Android 1.6 Donut), the current suggested way of getting the API level would be to check the value of android. os. Build. VERSION.

What is API level in choosing a version in targeting Android application?

API Level is an integer value that uniquely identifies the framework API revision offered by a version of the Android platform. The Android platform provides a framework API that applications can use to interact with the underlying Android system.


2 Answers

You can find a breakdown of the different versions of Android in use here. Currently, if you target 2.1 (API 7) you'll only miss out on about 3% of the market. Targeting 2.2 will miss just under 20%, or a fifth of the market.

As for converting your app, you can check what API level things are available for in the Android Reference. You'll note a checkbox and dropdown menu on the top right of the browsing area that allows you to filter by API level - that's one way to help converting. The other is to set the target and minimum SDK versions which will help Eclipse know what to complain about in your code. The easiest way to see if something needs conversion, however, is to emulate and test.

EDIT: The API level dropdown moved from the top right to the top left, over the list of APIs.

like image 101
thegrinner Avatar answered Sep 22 '22 07:09

thegrinner


This graph may help you make up your mind.

like image 39
Earl Avatar answered Sep 21 '22 07:09

Earl