# Producing an Android Build

Moropo supports running tests on Android using a `.apk` build file.

Please note:

* Play Store Android App Bundles (`.aab`) files are **not supported** - you must upload a `.apk` file
* Your `.apk` should be compatible with [x86\_64](https://developer.android.com/ndk/guides/abis#86-64) architecture

## Which build type should I use?

You can use a Debug or Release build set to use any backend environment.

Many Moropo users configure different test setups for different build types. For example:

* a Debug build using your Dev Environment that runs a regression suite on each pull request for a single device
* a Release build using your Staging Environment that runs a full test suite before each production release across a wide range of devices

## Using Gradle to produce a `.apk`

If you're comfortable with the terminal and have a natively-built Android app, you can use [Gradle](https://gradle.org/) to produce your build file:

To produce a debug build, run `./gradlew assembleDebug` in your terminal.

To produce a release build, run `./gradlew assembleRelease` in your terminal.

The `.apk` will be exported to your configured output directory, typically: `~/build/outputs/apk/`

## Using Android Studio to produce a `.apk`

1. Launch Android Studio
2. Open your project
3. Click on the **Build** menu in the top bar, then select **Build Bundle(s) / APK(s)**, then **Build APK(s)**.\
   ![](/files/ykj2kPhlLvqsjrVrVyXH)
4. Wait for your build to complete.
5. Press the **locate** button on the notification (bottom right) to open your file system and access the `.apk`

## \[React Native] Using Expo EAS to produce a `.apk`

If your app is built using React Native, you can use [Expo Application Services](https://expo.dev/eas) to build your app.

Ensure your `eas.config` includes the correct setting:

```json
{
  "build": {
    "myProfile": {
      "android": {
        "buildType": "apk"
      }
    }
  }  
}    
```

*Note: EAS allows a `.apk` to be produced using various config options; read the* [*official docs*](https://docs.expo.dev/build-reference/apk/)*.*

Run EAS via your terminal to trigger the build:&#x20;

```
eas build -p android --profile myProfile
```

## Using Flutter to produce a `.apk`

If your app is built using Flutter, you can use the `flutter` command line inside your terminal.

To produce a Debug build, run `flutter build apk --debug`.

To produce a Release build, run `flutter build apk`.

Your `.apk` will appear in the `./build/app/outputs/` folder.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.moropo.com/uploading-your-app/producing-an-android-build.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
