Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8024415
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T22:52:00+00:00 2026-06-04T22:52:00+00:00

Can you explain to me how I should determine the correct value for targetSdkLevel

  • 0

Can you explain to me how I should determine the correct value for targetSdkLevel?

Let’s say I want to build an app that works on all the versions from android 2.3.7 to 4.0.3, how should I set minSdkLevel and targetSdkLevel?

The former should match the API level of android 2.3.7 and the latter should match the API level of 4.0.3?

Then, when I develop my app, should I use only Methods/classes available in the oldest supported sdk level?

When I compile the app does it compile for 2.3.7 or 4.0.3?

I can not understand the purpose of targetSdkLevel, since the apk can not be compiled for the newer version specified in this tag, otherwise it could not work on versions down to the one specified by minSdkLevel… Why should I not set targetSdkLevel to the latest available level?

I’ve read also the official info about uses-sdk Manifest tag, but I still do not understand.. Can you help me clarifying this topic?

EDIT: thanks to all of you and excuse me for the duplicate question. I’ve read this Blog post and it really helped me. Great answers from all of you.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T22:52:02+00:00Added an answer on June 4, 2026 at 10:52 pm

    You should only use methods/classes available in the SDK specified by minSdkLevel, or otherwise wrap them with a proper check for the runtime API version.

    Your application will be compiled with the SDK specified in the project itself, not by the one specified by either minSdkLevel nor targetSdkLevel.

    You should set targetSdkLevel to the highest level API that you have tested the application with. This is because compatilibity behavior will be enabled/disabled for your application based on this value.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Can anyone please explain me the meaning of implementing Map class and how should
I don't get it - can someone please explain to me why I should
Anyone can explain in details what the following macro does? #define write_XDATA(address,value) (((char *)0x010000)
I hope this I can explain what I am trying to achieve: I want
I hope I can explain this well enough so that you can understand the
Not sure if this is the right terminology, let me explain what I want.
Can someone explain how should the predefine predicate forall to find the minimum values
anyone can explain me, why this parts of code are acting differently? while((c =
Hopefully someone can explain some behavior to me. I have a JSF page with
Hopefully I can explain this clearly. I'm looking to have a two sliders, and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.