Skip to content
tezvyn:
Menu

Archiving a React Native iOS App for Release

Source: reactnative.devEasyHow cards are made

Archiving creates a production-ready package for the App Store by bundling your JavaScript and disabling dev menus. This is the final step before submitting to TestFlight or for review.

Why it exists

Simulator and debug builds are for development convenience, often relying on a connection to your computer and including developer tools. To submit to the Apple App Store, you need a standalone, optimized, and secure version of your app that any user can download and run. Archiving is the official Xcode process to create this distributable package.

The mental model

Think of archiving as creating a master copy. During development, you work with rough drafts (debug builds) that have notes in the margins (the dev menu). Archiving is the process of typesetting, printing, and binding the final book that's ready for the bookstore shelf (the App Store). It's self-contained, optimized, and ready for public distribution.

How it works

The process happens in Xcode. First, you must configure your project to use the "Release" build scheme. This is critical because the Release scheme automatically disables the developer menu and ensures your JavaScript bundle is included locally within the app. You set this via Product -> Scheme -> Edit Scheme. Next, you select "Any iOS Device (arm64)" as your build target, which is a generic target for creating a distributable binary, not a specific connected device. The main action is Product -> Archive. This compiles your native code and bundles the React Native JavaScript into a single package. After a successful archive, Xcode's Organizer window appears. From there, you click "Distribute App" to upload it to App Store Connect for TestFlight beta testing or App Store submission.

When to use it

Use the archive process only when you are ready to distribute your app outside your development machine. This is the required workflow for submitting to TestFlight for internal or external beta testing, and for submitting your app to the App Store for review.

When not to use it

Do not archive for regular development and debugging. For daily work, running the app on a simulator or a physical device in Debug mode is much faster. The Debug scheme uses a local server to provide the JavaScript bundle, allowing for fast refresh and hot reloading, which are disabled in a release archive. Archiving is a heavyweight process meant for final packaging, not iterative development.

One canonical example

A developer finishes a new feature. After local testing, they are ready for QA. They open the project's .xcworkspace file in Xcode, select Product -> Scheme -> Edit Scheme, and confirm the "Run" action uses the "Release" build configuration. They then select "Any iOS Device (arm64)" as the target and choose Product -> Archive. Once complete, they use the "Distribute App" button to upload the build to App Store Connect, making it available to their QA team via TestFlight.

Interview question

What is the primary reason for archiving a React Native iOS application?

  • a.To quickly rebuild the JavaScript bundle without recompiling native code.
  • b.To generate an optimized, self-contained package for App Store submission.Correct
  • c.To enable hot reloading and developer menus for efficient debugging.
  • d.To test new features on any connected physical iOS device.
Why?

Archiving creates an optimized, standalone package suitable for public distribution to the App Store or TestFlight, as it bundles JavaScript locally and disables developer tools. Options like hot reloading or developer menus are features of debug builds, not archived release builds.

Just read this? Test yourself on what you have been reading.

Read the original → reactnative.dev

Put your scrolling time to good use

Learn one idea, try a quiz and save useful cards for revision. Tezvyn makes it easy to learn and stay current in your tech field, a few minutes at a time.

The iPhone app is on the way

We are building it. Until it lands, nothing here is held back from you: every interview card, your saved cards, streaks and the job board all work in Safari, plus hundreds of free practice quizzes of thirty questions each. Sign in and it all carries over to the app the day it arrives.

Want it as an icon? Tap Share at the bottom of Safari, then Add to Home Screen. It opens full screen and the cards you have read stay available offline.

Get it on Google PlayiPhone app coming soon

We are hiring for this. Open roles that interview on react-native — each one lists the topics its interview covers.

See open roles