Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to set minimum android version support in ionic +react + capacitor project?

I don't know how to set the minimum version of android to support, the apk created works only in new versions of android and doesn't work on older ones, i am a web developer and never developed anything related to android before, should i install sdk platforms related to that version on android studio or there is a certain config to change in my development files???

like image 834
Code Eagle Avatar asked Oct 21 '25 09:10

Code Eagle


1 Answers

If you are using the latest Capacitor version (v4) you can set the minimum and target SDK version in android/variables.gradle.

ext {
    minSdkVersion = 21
    compileSdkVersion = 30
    targetSdkVersion = 30
    ...
}

Latest documentation

like image 92
leonardofmed Avatar answered Oct 23 '25 22:10

leonardofmed



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!