Monaca Docs
  • Monaca
  • Create Your First App
  • Release Notes and Updates
    • Privacy Manifest Requirement for iOS Apps
    • Plugin uses-permission Tag Deduplication Feature
    • iOS Monaca Debugger Discontinuation & Alternative Features
    • Error submitting to iOS App Store (ITMS-90165)
    • Build error in cordova-custom-config
    • Cordova 11 changes
    • Cordova 10 changes
    • Cordova 9 changes
    • New Monaca CLI and Localkit
    • Migration from Cordova to Capacitor
  • Product Guides
    • Monaca Development Overview
    • Monaca Cloud IDE
      • Overview
      • Features in the Monaca Cloud IDE
      • Integrated Terminal
      • Editor Shortcuts
      • Project Dependencies
        • File and Folder Structure
        • JS/CSS Components
        • Cordova Plugins
        • Custom Cordova Plugins
      • Version Control
        • Introduction
        • GitHub Integration
        • Git SSH Integration
      • Monaca CI
        • Overview
        • Deploy Services
        • Deploy to Appetize.io
        • Deploy to DeployGate
        • Deploy to Firebase
      • Build
        • Building for iOS
          • Building an iOS App
          • Build Settings between Monaca and Xcode
        • Building for Android
        • Building for Electron
          • Building on Windows
        • Building for PWA
        • Building for Windows
        • Build Environment Settings
        • Common Build and Application Upload Errors
        • Build History
      • Distribution
        • App Store Distribution
          • App Store Connect Guide
          • iOS App Upload Feature
        • Google Play Distribution
        • Amazon Appstore Distribution
        • Non-market App Distribution
      • Download App Package
      • Tutorial
    • Monaca Localkit
      • Overview
      • Pairing and Debugging
      • Remote Building and Publishing
      • Troubleshooting Guide
      • Tutorial
    • Monaca CLI
      • Overview
      • Monaca CLI Commands
      • Pairing and Debugging
      • Project Dependencies
        • File and Folder Structure
        • JS/JSS Components
        • Cordova Plugins
        • Custom Cordova Plugins
      • Remote Building and Publishing
      • Troubleshooting Guide
      • Tutorial
    • Monaca Debugger
      • Functionalities
      • Installation
        • Monaca Debugger for Android
        • Monaca Debugger for iOS
        • Monaca Debugger for Android Emulator
      • Usage
      • Custom Build Debugger for iOS
      • iOS App Simulator Build
      • Troubleshooting Guide
      • Tutorials
    • Team Dashboard
    • Quick Viewer
    • Migrating from Other Platforms
      • Key Points
      • Cloud IDE preview function settings
      • Migrating from Angular
      • Migrating from Ionic
      • Migrating from React
      • Migrating from Vue
      • Migrating from PhoneGap
        • Key Differences
        • Guide for PhoneGap Build Users
        • Guide for PhoneGap CLI Users
        • Guide for PhoneGap Desktop App Users
      • Migrating from Telerik
  • Build App
    • Build for iOS
      • Creating a Private Key and CSR
      • Creating a Certificate
      • Updating Provisioning Profiles
  • Tutorials
    • Monaca Cloud IDE Tutorial
      • Part 1: Starting a Project
      • Part 2: Running Monaca Debugger with Monaca Cloud IDE
      • Part 3: Building a Monaca App
      • Part 4: Publishing a Monaca App
    • Monaca Localkit Tutorial
      • Part 1: Starting a Project
      • Part 2: Running Monaca Debugger with Monaca Localkit
      • Part 3: Building a Monaca App
      • Part 4: Publishing a Monaca App
    • Monaca CLI Tutorial
      • Part 1: Starting a Project
      • Part 2: Running Monaca Debugger with Monaca CLI
      • Part 3: Building a Monaca App
      • Part 4: Publishing a Monaca App
    • Electron Tutorial
      • How to Use a NPM Package
      • How to Use a Web API
    • Barcode Scanner Plugin
    • Cordova SQLite Storage Plugin
    • Cordova Google Analytics Plugin
    • Cordova Firebase Plugin
    • Cordova In-app Purchase Plugin
    • Cordova AppVersion Plugin
    • Cordova Ionic Keyboard Plugin
    • Cordova Social Sharing Plugin
    • NIFCLOUD mobile backend
    • Phonegap Push Plugin
  • API Reference
    • Monaca API
      • Monaca Cloud & Remote Build API Guide
      • Utilities
    • Core Cordova Plugins
      • Cordova 11.0
        • Battery Status Plugin
        • Camera Plugin
        • Device Plugin
        • Device Motion Plugin
        • Device Orientation Plugin
        • Dialogs Plugin
        • File Plugin
        • Geolocation Plugin
        • InAppBrowser Plugin
        • Media Plugin
        • Media Capture Plugin
        • Network Information Plugin
        • Splashscreen Plugin
        • Vibration Plugin
        • StatusBar Plugin
      • Cordova 10.0
        • Battery Status Plugin
        • Camera Plugin
        • Device Plugin
        • Device Motion Plugin
        • Device Orientation Plugin
        • Dialogs Plugin
        • File Plugin
        • Geolocation Plugin
        • InAppBrowser Plugin
        • Media Plugin
        • Media Capture Plugin
        • Network Information Plugin
        • Splashscreen Plugin
        • Vibration Plugin
        • StatusBar Plugin
        • Whitelist Plugin (Android Only)
      • Cordova 9.0
        • Battery Status Plugin
        • Camera Plugin
        • Contacts Plugin
        • Device Plugin
        • Device Motion Plugin
        • Device Orientation Plugin
        • Dialogs Plugin
        • File Plugin
        • File Transfer Plugin
        • Geolocation Plugin
        • Globalization Plugin
        • InAppBrowser Plugin
        • Media Plugin
        • Media Capture Plugin
        • Network Information Plugin
        • Splashscreen Plugin
        • Vibration Plugin
        • StatusBar Plugin
        • Whitelist Plugin (Android Only)
    • Third-party Cordova Plugins
      • Advanced HTTP Plugin
      • PhoneGap BarcodeScanner Plugin
      • Cordova Custom Config Plugin
      • DatePicker Plugin
      • Share Plugin (Android)
      • WebIntent Plugin (Android)
    • Monaca Power Plugins
      • Monaca HTML5 Resource Encryption
      • Monaca In-App Updater
      • Monaca Secure Storage
      • Barcode Scanner Plugin
      • Android build memory size setting
    • Service Integration
      • Repro
      • AppsFlyer
    • Configuration Files
      • Android
        • Android Configuration
        • config.xml
        • AndroidManifest.xml
      • iOS
        • iOS Configuration
        • config.xml
        • MonacaApp-Info.plist
  • Samples & Tips
    • Sample Apps
      • AdMob
      • Twitter Single Sign-on App
      • Facebook Single Sign-on App
      • Flickr
      • TODO App
      • BirthYear App
      • Break the Bricks
      • Train Catalog App
      • Omikuji Fortune Telling App
      • Clock App
      • Memo Application
      • RSS Reader App
      • Hello World App
    • Tips & Tricks
      • Playing Sound and Music
      • Control the Splash Screen
      • Using Database
  • Features
    • Push Notification
    • SNS Authentication
    • Database
  • FAQ
    • General
    • IDE
    • Build
    • Release
    • Subscription
      • How to Use Activation Code
    • Application
    • Usage
    • Debugger
  • Supported Environments
  • Trouble Shooting
    • Preview Log repeats to reload (Vue packages version mismatch error)
  • Monaca Product Website
  • 日本語
Powered by GitBook
On this page
  • Prerequisites
  • Types of build
  • Step 1: Configure an iOS app in Monaca
  • Configure iOS app settings
  • Configure iOS build settings
  • Step 2: Configure iOS app in Apple Developer Program
  • Generate a certificate
  • Register an App ID
  • Register a development device
  • Create a provisioning profile
  • Step 3: Build an app

Was this helpful?

  1. Product Guides
  2. Monaca Cloud IDE
  3. Build
  4. Building for iOS

Building an iOS App

PreviousBuilding for iOSNextBuild Settings between Monaca and Xcode

Last updated 1 year ago

Was this helpful?

Starting from April 2024, all iOS apps submitted to the App Store will need to be built with the iOS 17 SDK or later. For more information, see . Because of this, in order to publish Monaca apps to the App Store, you must use Cordova 12.0 or higher in your projects.

Prerequisites

Before getting started, you should:

  • subscribe to the .

  • understand the and their requirements.

Types of build

In Monaca, the iOS apps have three types of build: debug, test and release. The differences between these types of build are as follows:

Type of Build

Description

Requirements

Installation

Debug Build

Building the app for installing on development devices.

  • Development Certificate

  • Development Provisioning Profile

  • Apple Configurator 2 (Mac only)

Ad Hoc Build

Building the app for installing on a limited group of devices.

  • Production Certificate

  • Distribution (Ad Hoc) Provisioning Profile

  • Apple Configurator 2 (Mac only)

  • QR Code

In-house Build

Building the app for distribution outside the App Store.

  • Production Certificate

  • Distribution (In-house) Provisioning Profile

  • Apple Configurator 2 (Mac only)

  • QR Code

Release Build

Building the app for distribution in App Store.

  • Production Certificate

  • Distribution (App Store) Provisioning Profile

  • App Store

Simulator Build

Building the app for testing on iOS simulator.

  • N/A

  • Xcode Simulator

Ad hoc distribution is a way to distribute your applications without going through the App Store. Currently, up to 100 applications which are built by using ad hoc provisioning profile can be shared with other iOS devices through ad hoc distribution. However, the application distribution from the developer organization will be limited to the development stakeholders.

Step 1: Configure an iOS app in Monaca

Configure iOS app settings

  1. From the Monaca Cloud IDE menu, go to Configure → App Settings for iOS.

  2. Fill in the app information:

    Field

    Description

    Application name

    The name representing your app in the App Store

    App ID

    A unique ID representing your app. It is recommended to use reverse-domain style (for example, mobi.monaca.appname). Only alphanumeric characters and periods (at least one period must be used) are allowed.

    Version Number

    The number representing the version of your app. It will be required when uploading your application via App Store Connect later (publishing process). It needs 3 numbers separated by dots (for example, 1.10.2). Each number should be in [0-99].

3. After finishing the configurations, click Save.

Configure iOS build settings

  1. From the Monaca Cloud IDE menu, go to Configure → iOS Build Settings .

2. Create a new private key or import an existing one. To create a new private key, click the Generate Key and CSR button and fill in the username (a name representing this new private key), email address (Apple ID) and your country.

3. After creating a new private key, a CRS file associated with the private key is also created. Download the CRS file by clicking the Export button. It will be used to issue the certificates later in the Apple Developer Program.

6. Upload the certificates and corresponding provisioning profiles to the Monaca Cloud.

You can upload multiple certificates and multiple corresponding provisioning profiles with the Monaca build interface.

Step 2: Configure iOS app in Apple Developer Program

  1. Go to Certificates, Identifiers & Profiles. The following page will open:

4. On this page, we are going to do 4 important things:

Generate a certificate

There are two types of certificates that can be issued in the Apple Developer Program:

  • Development: required for a debug build

  • Production: required for either an Ad hoc or a release build

In the following example, we will show you how to issue and download a development certificate:

  1. Select the Certificates item.

3. Choose iOS App Development and click Continue.

Choose App Store and Ad hoc if you want to issue a production certificate.

4. Click Continue again and upload the CSR file that you’ve downloaded from Monaca Cloud IDE earlier. Then, click Generate.

5. Now, your development certificate has been issued. Download it as you will need to upload it to the Monaca Cloud IDE later.

Follow the same instructions in order to create a production certificate.

Register an App ID

  1. Select the Identifiers item.

3. The App ID string contains two parts (prefix and suffix) separated by a period. Fill in the information of your App ID:

  • App ID Description: Description of your App ID. You cannot use special characters such as @, &, *, ' or ".

  • App ID Prefix: It is defined as your Team ID by default.

  • App ID Suffix: It is defined as a Bundle ID search string. There are two types of App ID Suffixes:

    Suffix

    Description

    Explicit App ID

    Wildcard App ID

    Register a wildcard App ID if you want to use a single App ID for building and installing multiple applications. Enter an asterisk (*) as the last digit in the Bundle ID field of wildcard App ID.

  • App Services: Select the services you want to enable in your app.

4. Then, click Continue. After reviewing your App ID’s info, click Submit. Now you have completed your App ID registration to the Apple Developer Program.

Register a development device

You are required to register your development device before creating a development or a distribution provisioning profile.

In order to register a device that you will be using during your app development, please follow the instructions below:

  1. Select the Devices item.

3. Fill in the information of your device.

  • Name: a name representing your device (Example: MyiPhone)

  • UDID: the unique device identifier of your device. You can find this identifier by connecting your iOS device to your computer. For macOS, you can check it from the serial number of the system information. For Windows, you can check it from the device instance path of Device Manager.

4. Then, press Continue. After reviewing your device’s info, click Register. Now you have completed your device registration into Apple Developer Program.

Create a provisioning profile

One last step before building your iOS app is creating a provisioning profile. There are two types of provisioning profiles:

  • Development: used with a development certificate for a debug build

  • Distribution: used with a production certificate for Ad hoc and

    release builds

In the following example, we will show you how to create a development provisioning profile:

  1. Select the Profiles item.

3. Choose iOS App Development and click Continue.

  • Choose Ad hoc if you want to create a distribution provisioning profile for an Ad hoc build.

  • Choose App Store if you want to create a distribution provisioning profile for a release build.

4. Select your App ID and click Continue.

5. Select the certificate(s) you want to include in this profile and click Continue.

6. Select the device you have previously registered for development and click Continue.

7. Input a name for the provisioning profile and click Generate.

8. Now your development provisioning profile is ready. Download it as you will need it when building your iOS app in Monaca later.

Follow the same instructions in order to create a distribution provisioning profile.

Step 3: Build an app

  1. From the Monaca Cloud IDE menu, go to Build → Build App for iOS .

  2. Select the type of build you want and click Start Build.

3. It may take several minutes for the build to complete. Once the build is completed, your built app is ready to be installed/downloaded. See the below screenshot as an example:

If you are using a simulator with macOS Catalina 10.15 or later, you need to run the following command in the terminal before running the app. It enables all the applications.

sudo spctl --master-disable To restore the setting, run the following command:

sudo spctl --master-enable

See Also:

The app ID (set in the Monaca app settings) cannot contain asterisk (*) or the build will fail. The App ID must be the same as the explicit app ID you register (or have registered) in Apple Developer Program. Read more on .

Currently, when you update either iOS’s App ID or Android’s package name, both of them will change. In other words, they are configured to be the same. However, it is possible to make them different. Please refer to .

If you import an existing private key, you will also need to upload the certificate associated with this private key to Monaca. Please refer to .

4. and download them.

5. and download them.

From , go to Account.

Sign in using the Apple ID and password you used to enroll in the Apple Developer Program. If you haven’t enrolled in the program yet, please subscribe .

After downloading the CSR file (refer to ), you can issue and download certificates in the Apple Developer Program.

Click the button:

Click the button:

Register an explicit App ID if you plan to incorporate app services such as a Game Center, In-App Purchase, Data Protection, and iCloud, or just want a provisioning profile for a single app. Enter a unique string in the Bundle ID field of Explicit App ID which should match with the Bundle ID of your app. The App ID must match the one you set in Monaca Cloud IDE as shown in .

Click the button:

macOS
Windows

Click the button.

âž•
âž•
âž•
âž•
Apple Developer page
here
Building for Android
Building for Windows
App Store Distribution
Build History
Submitting iOS Apps to the App Store
Apple Developer Program
Types of Build
Register App ID
Issue certificates in Apple Developer Program
Create provisioning profiles in Apple Developer Program
Generate a certificate
Register an App ID
Register a development device
Create a provisioning profile
Configure iOS build settings
Simulator on browser
Configure iOS App Settings
Can the iOS' App ID and Android's package name be different?
Import private key and certificate into Monaca
Network Install