DEV Community

Cover image for How to create production builds for App Store and Play Store with EAS/Expo and React Native
Alexandre C.
Alexandre C.

Posted on • Edited on

7

How to create production builds for App Store and Play Store with EAS/Expo and React Native

Through this guide I will walktrough the steps that are required to create production builds with EAS that are ready to be deployed on the stores.

Prerequisites

In order to follow it you must have the eas-cli installed on your machine. If it is not the case you can run from a terminal ```npm

install -g eas-cli


According to [Expo documentation](https://docs.expo.dev/build/setup/) with EAS CLI you can either deploy a bare React Native app or an app that has been created with Expo.

## Login into your Expo account

First you need to login by typing into a terminal ```eas

 login

Enter fullscreen mode Exit fullscreen mode

If you are already signed in to an Expo account using Expo CLI, you can skip this step you should be already automatically logged in

Configure the project

Then you need to configure both iOS and Android for EAS build ```eas

build:configure


In `app.json` or `app.config.js` file I **strongly recommend** to configure the build number and version code which must match your package.json version, because EAS prevents you to submit twice the same app version, so you have to increase it manually to bypass EAS checks.

Example for the 1st release :

> app.json (or app.config.js)

![version 1](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/5joooc083keaac320496.png)

Example for the 2nd release :

> app.json (or app.config.js)

![version 2](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/a3zsmsd0ljfw7da27x5o.png)

## Build for app stores

You must have a [Google developer account](
Google Play Consolehttps://play.google.com › signup) and a [Apple developer account](
Apple Developerhttps://developer.apple.com)

You can create separate build for Android ```eas

 build --platform android

Enter fullscreen mode Exit fullscreen mode

Or iOS ```eas

build --platform ios


But it is better to create builds for both platforms at the same time ```eas

 build --platform all

Enter fullscreen mode Exit fullscreen mode

Everything should be handled automatically by EAS now, you can follow the progress from the terminal. But if you don't want to wait you can escape the terminal when it tells you to exit with Ctrl+C / Cmd+C

By accessing your Expo dashboard you can check if the builds are deployed and download them to upload them in the stores

Example of Expo dashboard

Expo dashboard

Enjoy your new builds

When builds are successfully created it should generate a .ipa file for iOS and .aab file for Android.
These are the files that you have to upload on Google Play Console and Apple Developer Dashboard to submit your app to the stores

iOS Expo build
Android Expo build

More details

To get more information about configuration and other things you should refer to the official documentation of EAS Build

Image of Timescale

Timescale – the developer's data platform for modern apps, built on PostgreSQL

Timescale Cloud is PostgreSQL optimized for speed, scale, and performance. Over 3 million IoT, AI, crypto, and dev tool apps are powered by Timescale. Try it free today! No credit card required.

Try free

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

👋 Kindness is contagious

Discover a treasure trove of wisdom within this insightful piece, highly respected in the nurturing DEV Community enviroment. Developers, whether novice or expert, are encouraged to participate and add to our shared knowledge basin.

A simple "thank you" can illuminate someone's day. Express your appreciation in the comments section!

On DEV, sharing ideas smoothens our journey and strengthens our community ties. Learn something useful? Offering a quick thanks to the author is deeply appreciated.

Okay