Movatterモバイル変換


[0]ホーム

URL:


Skip to main content

docs.flutter.dev uses cookies from Google to deliver and enhance the quality of its services and to analyze traffic.

Learn more

Flutter 3.41 is live! Check out theFlutter 3.41 blog post!

Build and release an iOS app

How to release a Flutter app to the App Store.

This guide provides a step-by-step walkthrough of releasing a Flutter app to theApp Store andTestFlight.

Preliminaries

#

Xcode is required to build and release your app. You must use a device running macOS to follow this guide.

Before beginning the process of releasing your app, ensure that it meets Apple'sApp Review Guidelines.

To publish your app to the App Store, you must first enroll in theApple Developer Program. You can read more about the various membership options in Apple'sChoosing a Membership guide.

Video overview

#

For those who prefer video over text, the following video covers the same material as this guide.

Watch on YouTube in a new tab: "Release an iOS app built with Flutter in 7 steps"

Register your app on App Store Connect

#

Manage your app's life cycle onApp Store Connect (formerly iTunes Connect). You define your app name and description, add screenshots, set pricing, and manage releases to the App Store and TestFlight.

Registering your app involves two steps: registering a unique Bundle ID, and creating an application record on App Store Connect.

For a detailed overview of App Store Connect, see theApp Store Connect guide.

Register a Bundle ID

#

Every iOS application is associated with a Bundle ID, a unique identifier registered with Apple. To register a Bundle ID for your app, follow these steps:

  1. Open theApp IDs page of your developer account.
  2. Click+ to create a new Bundle ID.
  3. Enter an app name, selectExplicit App ID, and enter an ID.
  4. Select the services your app uses, then clickContinue.
  5. On the next page, confirm the details and clickRegister to register your Bundle ID.

Create an application record on App Store Connect

#

Register your app on App Store Connect:

  1. OpenApp Store Connect in your browser.
  2. On the App Store Connect landing page, clickApps.
  3. Click+ in the top-left corner, then selectNew App.
  4. Fill in your app details in the form that appears. In the Platforms section, ensure that iOS is checked. Since Flutter does not currently support tvOS, leave that checkbox unchecked. ClickCreate.
  5. Navigate to the application details for your app and selectApp Information from the sidebar.
  6. In the General Information section, select the Bundle ID you registered in the preceding step.

For a detailed overview, seeAdd an app to your account.

Review Xcode project settings

#

This step covers reviewing the most important settings in the Xcode workspace. For detailed procedures and descriptions, seePrepare for app distribution.

Navigate to your target's settings in Xcode:

  1. Open the default Xcode workspace in your project by runningopen ios/Runner.xcworkspace in a terminal window from your Flutter project directory.
  2. To view your app's settings, select theRunner target in the Xcode navigator.

Verify the most important settings.

In theIdentity section of theGeneral tab:

Display Name

The display name of your app.

Bundle Identifier

The App ID you registered on App Store Connect.

In theSigning & Capabilities tab:

Automatically manage signing

Whether Xcode should automatically manage app signing and provisioning. This is settrue by default, which should be sufficient for most apps. For more complex scenarios, see theCode Signing Guide.

Team

Select the team associated with your registered Apple Developer account. If required, selectAdd Account..., then update this setting.

In theDeployment section of theBuild Settings tab:

iOS Deployment Target

The minimum iOS version that your app supports. Flutter supports iOS 13 and later. If your app or plugins include Objective-C or Swift code that makes use of APIs newer than iOS 12, update this setting to the highest required version.

TheGeneral tab of your project settings should resemble the following:

Xcode Project Settings

For a detailed overview of app signing, seeCreate, export, and delete signing certificates.

Add an app icon

#

When a new Flutter app is created, a placeholder icon set is created. This step covers replacing these placeholder icons with your app's icons:

  1. Review theiOS App Icon guidelines and, in particular, the advice oncreating light, dark, and tinted icons for your app.
  2. In the Xcode project navigator, selectAssets.xcassets in theRunner folder. Update the placeholder icons with your own app icons.
  3. Verify the icon has been replaced by running your app usingflutter run.

Add a launch image

#

Similar to the app icon, you can also replace the placeholder launch image:

  1. In the Xcode project navigator, selectAssets.xcassets in theRunner folder. Update the placeholder launch image with your own launch image.
  2. Verify the new launch image by hot restarting your app. (Don't usehot reload.)

Create a build archive and upload to App Store Connect

#

During development, you've been building, debugging, and testing withdebug builds. When you're ready to ship your app to users on the App Store or TestFlight, you need to prepare arelease build.

Update the app's build and version numbers

#

The default version number of the app is1.0.0. To update it, navigate to thepubspec.yaml file and update the following line:

yaml
version:1.0.0+1

The version number is three numbers separated by dots, such as1.0.0 in the example above, followed by an optional build number such as1 in the example above, separated by a+.

Both the version and the build number can be overridden influtter build ipa by specifying--build-name and--build-number, respectively.

In iOS,build-name usesCFBundleShortVersionString whilebuild-number usesCFBundleVersion. Read more about iOS versioning atCore Foundation Keys on the Apple Developer's site.

You can also override thepubspec.yaml build name and number in Xcode:

  1. OpenRunner.xcworkspace in your app'sios folder.
  2. SelectRunner in the Xcode project navigator, then select theRunner target in the settings view sidebar.
  3. In the Identity section, update theVersion to the user-facing version number you wish to publish.
  4. In the Identity section, update theBuild identifier to a unique build number used to track this build on App Store Connect. Each upload requires a unique build number.

Create an app bundle

#

Runflutter build ipa to produce an Xcode build archive (.xcarchive file) in your project'sbuild/ios/archive/ directory and an App Store app bundle (.ipa file) inbuild/ios/ipa.

Consider adding the--obfuscate and--split-debug-info flags toobfuscate your Dart code to make it more difficult to reverse engineer.

If you are not distributing to the App Store, you can optionally choose a differentexport method by adding the option--export-method ad-hoc,--export-method development or--export-method enterprise.

Note

On versions of Flutter whereflutter build ipa --export-method is unavailable, openbuild/ios/archive/MyApp.xcarchive and follow the instructions below to validate and distribute the app from Xcode.

Once the app bundle is created, upload it toApp Store Connect by either:

  1. Install and open theApple Transport macOS app.Drag and drop thebuild/ios/ipa/*.ipa app bundle into the app.

  2. Or upload the app bundle from the command line by running:

    bash
    xcrun altool --upload-app --type ios -f build/ios/ipa/*.ipa --apiKey your_api_key --apiIssuer your_issuer_id

    Runman altool for details about how to authenticate with the App Store Connect API key.

  3. Or openbuild/ios/archive/MyApp.xcarchive in Xcode.

    Click theValidate App button. If any issues are reported,address them and produce another build. You can reuse the samebuild ID until you upload an archive.

    After the archive has been successfully validated, clickDistribute App.

    Note

    When you export your app at the end ofDistribute App,Xcode will create a directory containingan IPA of your app and anExportOptions.plist file.You can create new IPAs with the same options without launchingXcode by runningflutter build ipa --export-options-plist=path/to/ExportOptions.plist.Seexcodebuild -h for details about the keys in this property list.

You can follow the status of your build in the Activities tab of your app's details page onApp Store Connect. You should receive an email within 30 minutes notifying you that your build has been validated and is available to release to testers on TestFlight. At this point you can choose whether to release on TestFlight, or go ahead and release your app to the App Store.

For more details, seeUpload an app to App Store Connect.

Create a build archive with Codemagic CLI tools

#

This step covers creating a build archive and uploading your build to App Store Connect using Flutter build commands andCodemagic CLI Tools executed in a terminal in the Flutter project directory. This allows you to create a build archive with full control of distribution certificates in a temporary keychain isolated from your login keychain.

  1. Install the Codemagic CLI tools:

    bash
    pip3 install codemagic-cli-tools
  2. You'll need to generate anApp Store Connect API Keywith App Manager access to automate operations with App Store Connect. To makesubsequent commands more concise, set the following environment variables fromthe new key: issuer id, key id, and API key file.

    bash
    export APP_STORE_CONNECT_ISSUER_ID=aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeeeexport APP_STORE_CONNECT_KEY_IDENTIFIER=ABC1234567export APP_STORE_CONNECT_PRIVATE_KEY=`cat /path/to/api/key/AuthKey_XXXYYYZZZ.p8`
  3. You need to export or create an iOS Distribution certificate to code sign and package a build archive.

    If you have existingcertificates, you can export theprivate keys by executing the following command for each certificate:

    bash
    openssl pkcs12 -in <certificate_name>.p12 -nodes -nocerts | openssl rsa -out cert_key

    Or you can create a new private key by executing the following command:

    bash
    ssh-keygen -t rsa -b 2048 -m PEM -f cert_key -q -N ""

    Later, you can have CLI tools automatically create a new iOS Distribution from the private key.

  4. Set up a new temporary keychain to be used for code signing:

    bash
    keychain initialize
    Restore Login Keychain!

    After runningkeychain initialize youmust run the following:

    keychain use-login

    This sets your login keychain as the default to avoid potentialauthentication issues with apps on your machine.

  5. Fetch the code signing files from App Store Connect:

    Wherecert_key is either your exported iOS Distribution certificate private keyor a new private key which automatically generates a new certificate. The certificatewill be created from the private key if it doesn't exist in App Store Connect.

  6. Now add the fetched certificates to your keychain:

  7. Update the Xcode project settings to use fetched code signing profiles:

  8. Install Flutter dependencies:

  9. Install CocoaPods dependencies:

  10. Build the Flutter the iOS project:

    Note thatexport_options.plist is the output of thexcode-project use-profiles command.

  11. Publish the app to App Store Connect:

  12. As mentioned earlier, don't forget to set your login keychainas the default to avoid authentication issueswith apps on your machine:

You should receive an email within 30 minutes notifying you that your build has been validated and is available to release to testers on TestFlight. At this point you can choose whether to release on TestFlight, or go ahead and release your app to the App Store.

TestFlight allows developers to push their apps to internal and external testers. This optional step covers releasing your build on TestFlight.

  1. Navigate to the TestFlight tab of your app's application details page onApp Store Connect.
  2. SelectInternal Testing in the sidebar.
  3. Select the build to publish to testers, then clickSave.
  4. Add the email addresses of any internal testers. You can add additional internal users in theUsers and Roles page of App Store Connect, available from the dropdown menu at the top of the page.

For more details, seeDistribute an app using TestFlight.

Release your app to the App Store

#

When you're ready to release your app to the world, follow these steps to submit your app for review and release to the App Store:

  1. SelectPricing and Availability from the sidebar of your app's application details page onApp Store Connect and complete the required information.
  2. Select the status from the sidebar. If this is the first release of this app, its status is1.0 Prepare for Submission. Complete all required fields.
  3. ClickSubmit for Review.

Apple notifies you when their app review process is complete. Your app is released according to the instructions you specified in theVersion Release section.

For more details, seeDistribute an app through the App Store.

Troubleshooting

#

TheDistribute your app guide provides a detailed overview of the process of releasing an app to the App Store.

Was this page's content helpful?

Unless stated otherwise, the documentation on this site reflects Flutter 3.38.6. Page last updated on 2025-12-15.View source orreport an issue.


[8]ページ先頭

©2009-2026 Movatter.jp