Expo

Documentation

Expo CLI

Expo CLI is a command line app that is the main interface between a developer and Expo tools. You'll use it for a variety of tasks, such as:
  • Creating new projects
  • Developing your app: running the project server, viewing logs, opening your app in a simulator
  • Publishing your app JavaScript and other assets and managing releasing them over the air
  • Managing Apple Credentials and Google Keystores
You may use the CLI in your terminal or use the web based interface (it opens automatically by default, or you can press d from the CLI to open it on demand). The web interface enables you to use some of the most often used features from a quick-to-use graphical interface. We’ve only scratched the surface of what expo-cli can do so far. Be sure to check out all the possible commands below!

npm install -g expo-cli

Run expo --version to determine what version you are currently working with.

The commands listed below are derived from the latest version of Expo CLI. You can view the list of commands available with your version in your terminal using expo --help. To learn more about a specific command and its options use expo [command] --help.
Usage: expo [command] [options]

expo android

Opens your app in the Expo client on a connected Android device.

OptionDescription
--offlineRun this command in offline mode.
--config [path]Specify a path to app.json.

expo build:ios

Build a standalone IPA for your project, signed and ready for submission to the Apple App Store.

Alias: expo bi
OptionDescription
--apple-id [id]Apple ID username. Set your Apple ID password as EXPO_APPLE_PASSWORD env variable.
--type, -t [type]Select the type of build: [archive or simulator] The default is archive.
--release-channel [channel]Pull bundle from specified release channel. If not specified, the default channel is used.
--no-publishPrevents an OTA update from occurring during the build process.
--no-waitExit immediately after scheduling build.
--team-id [id]Apple Team ID.
--dist-p12-path [path]Path to your Distribution Certificate. Set password as EXPO_IOS_DIST_P12_PASSWORD env variable.
--push-id [id]Push Notification Key. Example: 123AB4C56D
--push-p8-path [path]Path to your Push Notification Key .p8 file.
--provisioning-profile-path [path]Path to your provisioning profile.
--public-url [url]The url of an externally hosted manifest for self-hosted apps.
--config [path]Specify a path to app.json.

expo build:android

Build a standalone APK or App Bundle for your project, signed and ready for submission to the Google Play Store.

Alias: expo ba
OptionDescription
--release-channel [channel]Pull bundle from specified release channel. If not specified, the default channel is used.
--no-publishPrevents an OTA update from occurring during the build process.
--no-waitExit immediately after scheduling build.
--keystore-path [path]Path to your Keystore file.
--public-url [url]The url of an externally hosted manifest for self-hosted apps.
--type, -t [type]Select the type of build: [app-bundle or apk] The default is apk.
--config [path]Specify a path to app.json.

expo build:web

Build a production bundle for your project, compressed and ready for deployment.

OptionDescription
--pollyfillInclude @babel/polyfill.
--no-pwaPrevent webpack from generating the manifest.json and injecting meta into the index.html head.
--dev, -dTurns dev mode on before bundling
--config [path]Specify a path to app.json.

expo build:status

Gets the status of a current (or most recently finished) build for your project.

Alias: expo bs
OptionDescription
--public-url [url]The url of an externally hosted manifest for self-hosted apps.
--config [path]Specify a path to app.json.

expo bundle-assets

Bundles assets for a detached app. This command should be executed from xcode or gradle.

OptionDescription
--dest [dest]Destination directory for assets.
--platform [platform]Detached project platform.
--config [path]Specify a path to app.json.

expo client:ios

Build a custom version of the Expo Client for iOS using your own Apple credentials and install it on your mobile device using Safari.

OptionDescription
--apple-id[username]Apple ID username. Set your Apple ID password as EXPO_APPLE_PASSWORD env variable.
--config [path]Specify a path to app.json.

expo client:install:ios

Install the latest version of Expo client for iOS on the simulator.

expo client:install:android

Install the latest version of Expo Client for Android on a connected device or emulator.

expo credentials:manager

Manage your iOS or Android credentials.

OptionDescription
--platform, -p [platform]Select platform [android or ios]

expo customize:web

Generate static web files into your project.

OptionDescription
--force, -fAllows replacing existing files.
--offlineRun this command in offline mode.

expo diagnostics

Prints environment info to the console.

expo doctor

Diagnoses issues with your Expo project.

OptionDescription
--config [path]Specify a path to app.json.

expo eject

Creates Xcode and Android Studio projects for your app. Use this if you need to add custom native functionality.

OptionDescription
--eject-method [type]Eject method to use [expokit or plain]. If not specificed, the command will ask which to use. Required when using --non-interactive option.
--force, -fWill attempt to generate an iOS project even when the system is not running macOS. Unsafe and may fail.
--config [path]Specify a path to app.json.

expo export

Exports the static files of the app for hosting it on a web server.

OptionDescription
--public-url, -p [url]The public url that will host the static files. required
--output-dir [dir]The directory to export the static files to. Default directory is dist.
--asset-url, -aThe absolute or elative url that will host asset files. Default is ./assets which will be resolved agains the public-url.
--dump-assetmap, -dDump the asset map for further processing.
--devConfigures static files for developing locally using a non-https server.
--dump-sourcemap, -sDump the source map for debugging the JS bundle.
--quiet, -qSuppress the verbose output from React Native packager.
--merge-src-dir [dir]A repeatable source dir to merge in.
--merge-src-url [url]A repeatable source tar.gz file url to merge in.
--max-workers [number]Maxinum number of tasks to allow Metro to spawn.
--config [path]Specify a path to app.json.

expo fetch:ios:certs

Fetch this project's iOS certificates/keys and provisioning profile. Writes files to the PROJECT_DIR and prints passwords to stdout.

OptionDescription
--config [path]Specify a path to app.json.

expo fetch:android:keystore

Fetch this project's Android keystore. Writes keystore to PROJECT_DIR/PROJECT_NAME.jks and prints passwords to stdout.

OptionDescription
--config [path]Specify a path to app.json.

expo fetch:android:hashes

Fetch this project's Android key hashes needed to set up Google/Facebook authentication. Note: if you are using Google Play signing, this app will be signed with a different key after publishing to the store, and you'll need to use the hashes displayed in the Google Play console.

OptionDescription
--config [path]Specify a path to app.json.

expo fetch:android:upload-cert

Fetch this project's upload certificate needed after opting in to app signing by Google Play or after resetting a previous upload certificate.

OptionDescription
--config [path]Specify a path to app.json.

expo generate-module

Generate a universal module for Expo from a template in a directory.

OptionDescription
--template [dir]Local directory or npm package containing a template for a universal Expo module.

expo init

Initializes a directory with an example project. Run it without any options and you will be prompted for the name and type.

Alias: expo i
OptionDescription
--template, -t [name]Specify which template to use. Options are [blank, tabs or bare-minimum]
--npmUse npm to install dependencies. The default when Yarn is not installed.
--yarnUse Yarn to install dependencies. The default when Yarn is installed.
--name [name]The name of your app visible on the home screen.
--android-package [name]The package name for your Android app.
--ios-bundle-identifier [name]The bundle identifier for your iOS app.

expo install

Installs a unimodule or other package to a project.

OptionDescription
--npmUse npm to install dependencies. The default when package-lock.json exists.
--yarnUse Yarn to install dependencies. The default when yarn.lock exists.

expo ios

Opens your app in the Expo Client in an iOS simulator.

OptionDescription
--offlineRun this command in offline mode.
--config [path]Specify a path to app.json.

expo login

Login with your Expo account.

Alias: expo signin
OptionDescription
--username, -u[username]Expo username.
--password -p [password]Expo password.

expo logout

Log out from your Expo account.

expo opt-in-google-play-signing

Switch from the old method of signing APKs to the new App Signing by Google Play. The APK will be signed with an upload key and after uploading it to the store, app will be re-signed with the key from the original keystore.

OptionDescription
--config [path]Specify a path to app.json.

expo optimize

Compress the assets in your Expo project.

Alias: expo o
OptionDescription
--save, -sSave the original assets with an .orig extension.
--quality [number]Specify the quality of the compressed image. Default is 80.
--include [pattern]Include only assets that match this glob pattern relative to project root.
--exclude [pattern]Exclude all assets that match this glob pattern relative to project root.
--offlineRun this command in offline mode.

expo publish

Publishes your project to exp.host.

Alias: expo p
OptionDescription
--quiet, -qSuppress verbose output from React Native packager.
--send-to, -sA phone number or email address to send link to.
--clear, -cClear the React Native Packager cache.
--max-workers [number]Maximum number of tasks to allow Metro to spawn.
--release-channel [channel]The release channel to publish to. The default is 'default'.
--config [path]Specify a path to app.json.

expo publish:history

View a log of your published releases.

Alias: expo ph
OptionDescription
--release-channel, -c [channel]Filter by release channel. If this flag is not passed, the most recent publications will be shown.
--count [number]The number of logs to view. The default is 5. Maximum is 100.
--platform, -p [platform]Filter by platform. [android or ios]
--raw, -rProduce raw output.
--config [path]Specify a path to app.json.

expo publish:details

View the details of a published release.

Alias: expo pd
OptionDescription
--publish-id [id]Publication id. (required)
--raw, -rProduce raw output.
--config [path]Specify a path to app.json.

expo publish:set

Set a published release to be served from a specified channel.

Alias: expo ps
OptionDescription
--release-channel, -c [channel]The channel to set the published release.
--publish-id [id]The id of the published release to serve from the channel. (required)
--raw, -rProduce raw output.
--config [path]Specify a path to app.json.

expo publish:rollback

Rollback an update to a channel.

Alias: expo pr
OptionDescription
--channel-id [channel]The channel id to rollback in the channel. (required)
--config [path]Specify a path to app.json.

expo push:android:upload

Uploads a Firebase Cloud Messaging key for Android push notifications.

OptionDescription
--api-key [key]Server API key for FCM.
--config [path]Specify a path to app.json.

expo push:android:show

Print the value currently in use for FCM notifications for this project.

OptionDescription
--config [path]Specify a path to app.json.

expo push:android:clear

Deletes a previously uploaded FCM API key.

OptionDescription
--config [path]Specify a path to app.json.

expo register

Sign up for a new Expo account via terminal prompts.

expo send

Sends a link to your project to a specified email.

OptionDescription
--send-to, -s [email]Specifies what email to send project url to.
--android, -aOpens your app in the Expo client on a connected Android device.
--ios, -iOpens your app in the Expo client in a currently running iOS simulator on your computer.
--web, -wOpens your app in a web browser.
--host, -m [mode]Type of host to use. [lan, localhost or tunnel]. Tunnel allows you to view your link from other networks. Default is lan.
--tunnelSame as --host tunnel
--lanSame as --host lan
--localhostSame as --host localhost
--devTurns dev mode on.
--no-devTurns dev mode off.
--minifyTurns minfication on.
--no-minifyTurns minfication off.
--httpsStart a webpack with https protocol.
--no-httpsStart a webpack with http protocol.
--config [path]Specify a path to app.json.

expo start

Starts or restarts a local server for your app and gives you a url to it.

Alias: expo r
OptionDescription
--clear, -cClear the React Native Packager cache.
--max-workers [number]Maximum number of tasks to allow Metro to spawn.
--web-onlyOnly start the webpack server.
--send-to, -s [email]Specifies what email to send project url to.
--android, -aOpens your app in the Expo client on a connected Android device.
--ios, -iOpens your app in the Expo client in a currently running iOS simulator on your computer.
--web, -wOpens your app in a web browser.
--host, -m [mode]Type of host to use. [lan, localhost or tunnel]. Tunnel allows you to view your link from other networks. Default is lan.
--tunnelSame as --host tunnel
--lanSame as --host lan
--localhostSame as --host localhost
--devTurns dev mode on.
--no-devTurns dev mode off.
--minifyTurns minfication on.
--no-minifyTurns minfication off.
--httpsStart a webpack with https protocol.
--no-httpsStart a webpack with http protocol.
--offlineRun this command in offline mode.
--config [path]Specify a path to app.json.

expo upgrade

Upgrade your project to a newer SDK version.

OptionDescription
--npmUse npm to install updated packages.
--yarnUse yarn to install updated packages.

expo upload:android

Uploads a standalone Android app to Google Play (works on macOS only). Uploads the latest build by default.

Alias: expo ua
OptionDescription
--latestUploads the latest build. This is the default behavior.
--id [id]Id of the build to upload.
--path [path]Path to the desired .apk file.
--key [path]Path to the JSON key used to authenticate with Google Play.
--config [path]Specify a path to app.json.

expo upload:ios

Uploads a standalone app to Apple TestFlight (works on macOS only). Uploads the latest build by default.

Alias: expo ui
OptionDescription
--latestUploads the latest build. This is the default behavior.
--id [id]Id of the build to upload.
--path [path]Path to the desired .ipa file.
--apple-id [id]Apple ID username. You can also set your username as EXPO_APPLE_ID env variable.
--itc-team-id [id]App Store Connect Team ID (optional if there is only one team available).
--apple-id-password [password]Apple ID password. You can also set your password as EXPO_APPLE_ID_PASSWORD env variable.
--app-name [name]The name of your app as it will appear on the App Store. Max character limit is 30. Defaults to value from expo.name in your app.json
--sku [sku]A unqiue ID for your app that is not visible on the App Store. Will be generated if not provided.
--language [language]Primary language. Options: Brazilian Portuguese, Danish, Dutch, English, English_Australian, English_CA, English_UK, Finnish, French, French_CA, German, Greek, Indonesian, Italian, Japanese, Korean, Malay, Norwegian, Portuguese, Russian, Simplified Chinese, Spanish, Spanish_MX, Swedish, Thai, Traditional Chinese, Turkish, Vietnamese
--public-url [url]The url of an externally hosted manifest for self-host apps.
--config [path]Specify a path to app.json.

expo url

Displays the url you can use to view your project in Expo.

Alias: expo u
OptionDescription
--android, -aOpens your app in the Expo client on a connected Android device.
--ios, -iOpens your app in the Expo client in a currently running iOS simulator on your computer.
--web, -wOpens your app in a web browser.
--host, -m [mode]Type of host to use. [lan, localhost or tunnel]. Tunnel allows you to view your link from other networks. Default is lan.
--tunnelSame as --host tunnel
--lanSame as --host lan
--localhostSame as --host localhost
--devTurns dev mode on.
--no-devTurns dev mode off.
--minifyTurns minfication on.
--no-minifyTurns minfication off.
--httpsStart a webpack with https protocol.
--no-httpsStart a webpack with http protocol.
--config [path]Specify a path to app.json.

expo url:ipa

Displays the standalone iOS binary url you can use to download your app binary .

OptionDescription
--public-url [url]The url of an externally hosted manifest for self-host apps.
--config [path]Specify a path to app.json.

expo url:apk

Displays the standalone Android binary url you can use to download your app binary.

OptionDescription
--public-url [url]The url of an externally hosted manifest for self-host apps.
--config [path]Specify a path to app.json.

expo webhooks:sset

Set a webhook for the project.

OptionDescription
--url [url]Webhook to be called after building the app.
--event [type]The type of webhook: [build].
--secret [secret]Secret to be used to calculate the webhook request payload signature. See docs for more details. Must be 16 chars long.
--config [path]Specify a path to app.json.

expo webhooks:show

See webhooks for a project.

OptionDescription
--config [path]Specify a path to app.json.

expo webhooks:clear

Clear a webhook associated with an Expo project.

OptionDescription
--event [type]The type of webhook: [build].
--config [path]Specify a path to app.json.

expo whoami

Checks with the server to see if you are logged in and if you are, returns what Expo account you are logged in as.

These options will work with any command, eg: expo build:ios --help will provide help information relevant to the expo build:ios command.
OptionDescription
--help, -hReveals usage information.
-o, --output [format]The output format [pretty or raw]. The default is pretty.
--non-interactiveFails the command if an interactive prompt would be required to continue. Enabled by default if stdin is not a TTY.