50

I'm trying to generate a .ipa and a .apk file for my React Native app using Expo & Create React Native App. I successfully built the app and was able to get it to run on both an iOS & an Android device thanks to the docs: https://docs.expo.io/versions/v16.0.0/guides/building-standalone-apps.html

When the build is over, my console shows something like

Your URL is https://exp.host/@myname/myapp

I then open exp.host/@myname/myapp on my device and the app shows up via the Expo client.

But at point 4 of the docs, it is said that

When it’s done, you’ll see the url of a .apk (Android) or .ipa (iOS) file — this is your app.

I'm a bit confused. No where in the process do I see any ipa or apk file generated anywhere on my pc. Am I missing something ? How do I actually generate the files ?

1
  • The docs link you have shared in the question isn't valid anymore. I need a bit of guidance to do the same thing for my app. Do you have the updated source for same instructions?
    – Jordan
    Commented Nov 7, 2020 at 13:08

10 Answers 10

49

make sure in app.json

{
  "expo": {
    "name": "your app name",
    "description": "your app desc",
    ....,
    "ios": {
      "supportsTablet": true
    },
    
    "android": {
      "package": "com.yourcompany.yourappname"
    }
  }
}

then run expo build:android or expo ba

after that

run expo build:status you'll find, something like this, the Apk's is hosted on amazon aws

[exp] Android:
[exp] APK: https://HOST/yourapp.apk
3
  • Do I always need to manually type to copy the url for downloading apk? I am getting the url even able to download apk file but the only question is to is there any way to access directly? I dont want to type everytime. Commented Nov 26, 2017 at 9:51
  • 1
    @BilalHussain yes you have to copy the url manually to get the APK
    – Ansyori
    Commented Feb 7, 2018 at 4:00
  • You can use a url to get all the previous and current builds so you can monitor your builds in an easier way: stackoverflow.com/a/49048517/1042409
    – c-chavez
    Commented Mar 1, 2018 at 11:18
41

You will need to run expo build:status. When building process is complete you will see link to download apk (Android) or ipa(IOS) file.

4
  • 3
    Please ensure you have the exp command line tool installed: npm install -g exp
    – sisanared
    Commented Jun 26, 2018 at 11:18
  • 7
    In 2019, it's expo not exp . The link to the recent docs at this time of writing is expo-standalone-apps. According to the steps in the answer, you would need to run expo build:status rather than exp build:status and then after run expo build:android or expo build:ios depending on what OS you're building for. After running that you would be asked a couple of questions like if you want expo to handle everything, I'd suggest you do.
    – richard4s
    Commented Apr 13, 2019 at 13:26
  • 1
    No currently active or previous builds for this project. Commented Aug 4, 2020 at 11:45
  • 1
    expo build:android Commented Jul 4, 2021 at 4:01
8
  • use `expo build:android` for android
  • use `expo build:ios` for ios

it will ask to create new account if you don't have an expo account expo build:status to know status of your app & the queued app may take around 30 mins to generate apk file .
you can find it in expo website

how to generate apk/ios file from expo

8

Update For the Latest Version of expo:
Expo will soon deprecate expo build and has encouraged using eas build, which builds to app bundle by default. To build to apk, modify the eas.json file accordingly as given here in expo docs. You will ofcourse have to install eas separately as it doesn't come bundled with expo-cli.

For apk add eas.json as:

{
  "build": {
    "preview": {
      "android": {
        "buildType": "apk"
      }
    },
    "preview2": {
      "android": {
        "gradleCommand": ":app:assembleRelease"
      }
    },
    "preview3": {
      "developmentClient": true
    },
    "production": {}
  }
}

and then run eas build -p android --profile preview

3

As per https://docs.expo.dev/classic/building-standalone-apps/: "The Classic Build service (expo build:{android,ios}) is in maintenance mode and has been superseded by EAS Build. SDK 46 will be the last SDK supported by Classic Builds and the Classic Build service will stop running for all SDK versions after January 4, 2023.", the new commands are:

  • eas build --platform android for Android
  • eas build --platform ios for iOS
  • eas build --platform all for both

More information: https://docs.expo.dev/build/setup/.

3

This command will work

eas build -p android --profile preview

2

If you execute build status:

expo build:status

you will get the status update of the build either for ios or android. It will show one of these possible states:

  • Build in progress...
  • There was an error with this build
  • URL of the ipa or apk file

The URL would be something like:

https://expo.io/builds/{buildId}

where {buildId} is a UUID

When you click on the link, it will show the current status, logs being generated, a "Download" button where you can download the ipa or apk file (which will only be available if the build was successful) and a "Cancel" button to cancel the current build (which will only be available if the build is running).

Alternatively you can view your previous and current builds statuses by following this link:

https://expo.io/{@user}/{app}/builds

Replace {@user} with your expo username (including the @ character) and {app} with your app name. Here you can view specific build statuses like Completed or Failed, view logs of your builds, and download current and previous successful builds.

This URL is also shown when you go to your current build, below the "Build logs" title:

This is a build from {@user}/{app}

0

At first, Run this command -> expo build:android then

login your expo account

Choose the build type you would like: apk:normal apk file apk-bundle: for play store and app store

then generate a keystore file and wait minimum 10 minutes then your get a build link https://expo.dev/accounts/your_account_name/projects/project_name/builds/6ab79fef-72fe-4f50-88e2

goto thik link and download your build.

0

if you're using the new Expo Application Services (EAS) to build your React Native app, you can use the following command to generate an IPA file for IOS:

eas build -p ios --profile preview

And if you are using the Android so you can use :

eas build -p android --profile preview
0

expo build:android has been superseded by eas build.

(Learn more: https://blog.expo.dev/turtle-goes-out-to-sea-d334db2a6b60)

Run the following instead:

› npm install -g eas-cli
› eas build -p android 

ref - https://docs.expo.dev/build/setup/

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.