Flutter Lesson 78 of 83 5 min read
Build and Release a Flutter App for iOS
Publish a Flutter app on the App Store: Apple developer account, bundle id, signing in Xcode, flutter build ipa, TestFlight and review.
On this page
Releasing for iPhone and iPad follows the same shape as Android, with Apple’s tools. Apple’s requirements change often, so follow App Store Connect’s own guidance alongside this outline.
What you need #
- A Mac with a current version of Xcode. iOS apps cannot be built on Windows or Linux. Without a Mac, a cloud build service such as Codemagic can build for you.
- An Apple Developer Program membership, which has an annual fee.
- A real iPhone for testing is strongly recommended.
Before you build #
- App icon (no transparency), display name and bundle id are set. See icon, splash and name.
- Every permission the app uses has a usage description in
Info.plist. A missing one crashes the app, and a vague one causes rejection. -
versioninpubspec.yamlis correct. - The app has been tested with
flutter run --releaseon a real device.
1. Register the app #
In the Apple Developer website, under Identifiers, register an App ID with your bundle identifier, such as com.yourcompany.myshop. Enable any capabilities the app needs, such as push notifications or Sign in with Apple.
Then in App Store Connect, create a new app and select that bundle id. Choose the name carefully: it must be unique on the App Store.
2. Configure signing in Xcode #
Open the iOS project. Always open the workspace, not the project file:
open ios/Runner.xcworkspace
Select Runner in the left panel, then the Runner target, and check:
General tab
| Setting | Value |
|---|---|
| Display Name | The name under the icon |
| Bundle Identifier | The id you registered |
| Minimum Deployments | The lowest iOS version you support |
Signing & Capabilities tab
- Tick Automatically manage signing.
- Choose your Team.
Xcode then creates the certificates and provisioning profiles for you. Manual signing is rarely needed outside a CI system.
Version and build number come from pubspec.yaml, so leave those fields alone in Xcode.
3. Build the archive #
flutter build ipa
This produces:
- An Xcode archive in
build/ios/archive/. - An
.ipafile inbuild/ios/ipa/.
Options that mirror Android’s:
flutter build ipa --build-name=1.2.0 --build-number=7
flutter build ipa --obfuscate --split-debug-info=build/symbols
If the build fails on CocoaPods, this usually clears it:
cd ios
pod install --repo-update
cd ..
flutter clean
flutter pub get
4. Upload #
Any of these works:
- Transporter, a free Mac app from Apple. Drag the
.ipain and press Deliver. The simplest route. - Xcode: open the archive from Window, Organizer, then Distribute App.
- Command line:
xcrun altoolor the App Store Connect API, used in CI.
After the upload, Apple processes the build for some minutes before it appears in App Store Connect.
5. Test with TestFlight #
TestFlight is Apple’s testing service, and it is part of App Store Connect.
| Group | Who | Review needed |
|---|---|---|
| Internal testers | Members of your team | No. Available as soon as processing finishes |
| External testers | Anyone you invite by email or public link | A short beta review, the first time |
Testers install the TestFlight app and get your build through it. Always test the uploaded build this way before submitting. It is the exact binary that reviewers and users will get.
6. Prepare the listing #
In App Store Connect, fill in:
- Screenshots for the required iPhone sizes, and iPad if you support it.
- Description, keywords, support URL and marketing URL.
- Privacy policy URL.
- App Privacy: a questionnaire about what data is collected, including by third-party packages.
- Age rating questionnaire.
- Pricing and availability.
- Review information: contact details, and a demo account if the app needs a login. Reviewers cannot test what they cannot get into.
7. Submit for review #
Select the build, answer the export compliance question (about encryption), and submit. Review usually takes one to a few days.
Why apps are rejected #
Apple’s review is stricter than Google’s. The frequent causes:
| Reason | How to avoid it |
|---|---|
| Crashes or obvious bugs | Test the TestFlight build on a real device |
| No way for the reviewer to log in | Provide a working demo account |
| Vague permission descriptions | Say exactly what the data is used for |
| Sign-in with Google or Facebook, without Sign in with Apple | Offer Sign in with Apple as well, where the guidelines require it |
| Account creation without account deletion | Let users delete their account from inside the app |
| Selling digital goods without in-app purchase | Use Apple’s in-app purchase for digital content |
| Too little functionality | The app must do more than wrap a website |
| Placeholder content | Remove “lorem ipsum” and test data |
A rejection includes the reason. Fix it, reply in the Resolution Center, and resubmit. It is a normal part of the process.
Updates #
- Raise the version and build number in
pubspec.yaml. flutter build ipa, and upload.- In App Store Connect, create a new version, select the build, write “What’s New”, and submit.
You can release automatically after approval, on a date, or manually, and you can phase the release over seven days.
iPad and other details #
- An app that runs on iPad must work in both orientations and in split view, unless you opt out in the project settings. See responsive layouts.
- The share sheet and popovers need an anchor position on iPad.
- Push notifications, Sign in with Apple and in-app purchase each need extra setup in the developer portal and Xcode.
Try it yourself #
If you have a Mac and a developer account: register a bundle id, configure signing, build an .ipa and install it on your own phone through TestFlight as an internal tester. If you do not, write the usage descriptions your app would need in Info.plist, and a checklist of what you would give a reviewer.