Skip to content
distributing-tauri-for-android logo

Distributing Tauri Apps for Android

distributing-tauri-for-android

Guides the user through distributing Tauri applications for Android, including Google Play Store submission, APK and AAB generation, build configuration, signing setup, and version management.

SKILL.md

Full skill instructions

Distributing Tauri Apps for Android

This skill covers the complete workflow for preparing and distributing Tauri v2 applications on Android, including Google Play Store publication.

Prerequisites

Before distributing your Tauri app for Android:

  1. Play Console Account: Create a developer account at https://play.google.com/console/developers
  2. Android SDK: Ensure Android SDK is installed and configured
  3. Code Signing: Set up Android code signing (keystore)
  4. Tauri Android Initialized: Run tauri android init if not already done

App Icon Configuration

After initializing Android support, configure your app icon:

# npm
npm run tauri icon /​path/​to/​app-icon.png

# yarn
yarn tauri icon /​path/​to/​app-icon.png

# pnpm
pnpm tauri icon /​path/​to/​app-icon.png

# cargo
cargo tauri icon /​path/​to/​app-icon.png

This generates icons in all required sizes for Android.

Build Configuration

tauri.conf.json Android Settings

Configure Android-specific settings in your tauri.conf.json:

{
  "bundle": {
    "android": {
      "minSdkVersion": 24,
      "versionCode": 1
    }
  }
}

Configuration Options

OptionDefaultDescription
minSdkVersion24Minimum Android SDK version (Android 7.0)
versionCodeAuto-calculatedInteger version code for Play Store

Version Code Calculation

Tauri automatically calculates the version code from your app version:

versionCode = major * 1000000 + minor * 1000 + patch

Example: Version 1.2.3 becomes version code 1002003

Override this in tauri.conf.json if you need sequential numbering:

{
  "bundle": {
    "android": {
      "versionCode": 42
    }
  }
}

Minimum SDK Version

Default minimum is Android 7.0 (SDK 24). For higher requirements:

{
  "bundle": {
    "android": {
      "minSdkVersion": 28
    }
  }
}

Common SDK versions:

  • SDK 24: Android 7.0 (Nougat)
  • SDK 26: Android 8.0 (Oreo)
  • SDK 28: Android 9.0 (Pie)
  • SDK 29: Android 10
  • SDK 30: Android 11
  • SDK 31: Android 12
  • SDK 33: Android 13
  • SDK 34: Android 14

Building for Distribution

Android App Bundle (AAB) - Recommended

Google Play requires AAB format for new apps. Generate an AAB:

# npm
npm run tauri android build -- --aab

# yarn
yarn tauri android build --aab

# pnpm
pnpm tauri android build -- --aab

# cargo
cargo tauri android build --aab

Output location:

gen/​android/​app/​build/​outputs/​bundle/​universalRelease/​app-universal-release.aab

APK Generation

For testing or alternative distribution channels:

# npm
npm run tauri android build -- --apk

# yarn
yarn tauri android build --apk

# pnpm
pnpm tauri android build -- --apk

# cargo
cargo tauri android build --apk

Architecture-Specific Builds

Build for specific CPU architectures:

# Single architecture
npm run tauri android build -- --target aarch64

# Multiple architectures
npm run tauri android build -- --target aarch64 --target armv7

Available targets:

  • aarch64 - ARM 64-bit (most modern devices)
  • armv7 - ARM 32-bit (older devices)
  • i686 - Intel 32-bit (emulators)
  • x86_64 - Intel 64-bit (emulators, some Chromebooks)

Split APKs by Architecture

Create separate APKs per architecture (useful for testing):

npm run tauri android build -- --apk --split-per-abi

Note: Not needed for Play Store submission. Google Play automatically serves the correct architecture from your AAB.

Code Signing

Generate a Keystore

Create a release keystore for signing:

keytool -genkey -v -keystore release-key.keystore \
  -alias my-app-alias \
  -keyalg RSA \
  -keysize 2048 \
  -validity 10000

Important: Store your keystore securely. Losing it means you cannot update your app.

Configure Signing in Gradle

Create or update gen/​android/​keystore.properties:

storePassword=your_store_password
keyPassword=your_key_password
keyAlias=my-app-alias
storeFile=/​path/​to/​release-key.keystore

Update gen/​android/​app/​build.gradle.kts to use the keystore:

import java.util.Properties
import java.io.FileInputStream

val keystorePropertiesFile = rootProject.file("keystore.properties")
val keystoreProperties = Properties()
if (keystorePropertiesFile.exists()) {
    keystoreProperties.load(FileInputStream(keystorePropertiesFile))
}

android {
    signingConfigs {
        create("release") {
            keyAlias = keystoreProperties["keyAlias"] as String
            keyPassword = keystoreProperties["keyPassword"] as String
            storeFile = file(keystoreProperties["storeFile"] as String)
            storePassword = keystoreProperties["storePassword"] as String
        }
    }
    buildTypes {
        release {
            signingConfig = signingConfigs.getByName("release")
        }
    }
}

Environment Variables for CI/​CD

For automated builds, use environment variables:

android {
    signingConfigs {
        create("release") {
            keyAlias = System.getenv("ANDROID_KEY_ALIAS")
            keyPassword = System.getenv("ANDROID_KEY_PASSWORD")
            storeFile = file(System.getenv("ANDROID_KEYSTORE_PATH"))
            storePassword = System.getenv("ANDROID_STORE_PASSWORD")
        }
    }
}

Google Play Store Submission

Pre-Submission Checklist

  1. App signed with release keystore
  2. Version code incremented from previous release
  3. App icon configured in all required sizes
  4. Screenshots prepared (required by Play Store)
  5. Privacy policy URL ready (required for most apps)
  6. Content rating questionnaire completed

Upload Process

  1. Navigate to Play Console: https://play.google.com/console/developers
  2. Create application or select existing app
  3. Upload AAB file from:
    gen/​android/​app/​build/​outputs/​bundle/​universalRelease/​app-universal-release.aab
    
  4. Complete store listing (title, description, screenshots)
  5. Set content rating
  6. Configure pricing and distribution
  7. Submit for review

First Release Requirements

The initial submission requires manual upload through Play Console for signature verification. Google will manage your app signing key through Play App Signing.

Automation Note

Tauri currently does not offer built-in automation for creating Android releases. However, you can use the Google Play Developer API for automated submissions in CI/​CD pipelines.

Troubleshooting

Build Fails with Signing Error

Ensure your keystore path is absolute or relative to the correct directory:

# Absolute path
storeFile=/​Users/​username/​keys/​release-key.keystore

# Relative to gen/​android directory
storeFile=../​../​release-key.keystore

Version Code Not Incrementing

If using auto-calculation, ensure your package.json or Cargo.toml version is updated. For manual control:

{
  "bundle": {
    "android": {
      "versionCode": 2
    }
  }
}

APK Not Installing on Device

Check minimum SDK version compatibility:

# Check device Android version
adb shell getprop ro.build.version.sdk

AAB Too Large

Consider using --split-per-abi for testing, but for Play Store, Google handles this automatically. If still too large:

  1. Optimize your frontend assets
  2. Use dynamic feature modules
  3. Enable ProGuard/​R8 minification

Quick Reference

Common Build Commands

# Development build
npm run tauri android dev

# Release AAB for Play Store
npm run tauri android build -- --aab

# Release APK for testing
npm run tauri android build -- --apk

# Specific architecture
npm run tauri android build -- --aab --target aarch64

File Locations

FileLocation
AAB outputgen/​android/​app/​build/​outputs/​bundle/​universalRelease/​app-universal-release.aab
APK outputgen/​android/​app/​build/​outputs/​apk/​universal/​release/​app-universal-release-unsigned.apk
Gradle configgen/​android/​app/​build.gradle.kts
Keystore propertiesgen/​android/​keystore.properties
Android manifestgen/​android/​app/​src/​main/​AndroidManifest.xml

Resources

More skills from majiayu000

xiaohongshu logo
majiayu000/claude-arsenal

xiaohongshu

xiaohongshu

286 148
View
agent-task-conductor logo
majiayu000/claude-skill-registry

agent-task-conductor

Conduct multi-agent task orchestration and workflow coordination.

663 1
View
conductor-setup logo
majiayu000/claude-skill-registry

conductor-setup

Initialize project with Conductor artifacts (product definition,

663 1
View
animation-designer logo
majiayu000/claude-skill-registry

animation-designer

Expert in web animations, transitions, and motion design using Framer Motion and CSS

663 1
View
diagramming logo
majiayu000/claude-skill-registry

diagramming

Creates Mermaid and ASCII diagrams for flowcharts, architecture, ERDs, state machines, mindmaps, and more. Use when user mentions diagram, flowchart, mermaid, ASCII diagram, text diagram, terminal diagram, visualize, C4, mindmap, architecture diagram, sequence diagram, ERD, or needs visual docume...

663 1
View
h3-pg logo
majiayu000/claude-skill-registry-data

h3-pg

PostgreSQL bindings for H3 hexagonal grid system. Use when working with H3 cells in Postgres, including spatial indexing, geometry/geography integration, and raster analysis.

23 1
View
conductor-development logo
majiayu000/claude-skill-registry

conductor-development

Context-Driven Development skill for projects using Conductor. Use this skill when you detect a `conductor/` directory in the project, when working on tasks defined in a `plan.md` file, or when the user asks about tracks, specs, or plans. Automatically applies TDD workflow, tracks task completion...

663 1
View
conductor-status logo
majiayu000/claude-skill-registry

conductor-status

Display project status, active tracks, and next actions

663 1
View
dockerization logo
majiayu000/claude-skill-registry

dockerization

Official Stakpak application containerization standard operating procedure, a step-by-step guidline to properly dockerize applications. This is a rule book curated by the Stakpak Team.

663 1
View

Popular AI tools

Kaiber logo
Video

Kaiber

Generate, edit, and beat-sync AI video with leading models in one workspace.

Paid
View
Vimcal logo
Productivity

Vimcal

The world's fastest calendar for remote work

Free
View

Transform Your Design with AI Designer by ImgCreator.ai

Freemium
View
Akool AI logo
Content & writing

Akool AI

Revolutionizing Video Production with AI-Powered Creativity

Paid
View

Extend an image past the frame and let AI fill the new aspect ratio.

Freemium
View
StarByFace logo
Security

StarByFace

Discover your celebrity doppelgänger with StarByFace!

Free
View
C

ChainClarity explains 700+ crypto whitepapers in plain English, with layered summaries, comparisons, research tools, alerts, and a $4.99 Pro plan.

Freemium
View
Opus Clip logo
Coding & apps

Opus Clip

Opus.ai: Revolutionize Your Web Experience

Free
View