Setup Xcode

We use the Xcode to develop applications for the Apple Platform. This article introduce things to start developing.

TOC

Register to the Apple Developer Program

If you just want to develop an app, get documentation and sample code, and run the app you developed on your own device, you only need an Apple ID. You can use the Apple ID you use for iCloud, or you can create an Apple ID for development.

I use different Apple ID for development from daily use. The reason is that I became a member when the Apple Developer Program was Apple Developer Connection yet, and at that time, the Apple ID was not available yet.

Sometimes when I used Japanese for names and addresses would go wrong so I am glad I kept them separate. (I think it is fixed now.)

I recommend that you to be a member of the Apple Developer Program if you want to deploy your apps in the App Store. You need to pay member fee yearly, but when you are member you can get may benefits, you can generate the code signing certificates and sign your developed macOS applications with it, then your macOS application no longer blocked by the GateKeeper even they are deployed at out of the Mac App Store.

When you deploy the iOS apps, tvOS apps and watchOS apps, you must become a member of the Apple Developer Program. Apple Platform applications for other than macOS can be deployed in the App Store only. For the enterprise deployment, the App Store is not needed but the enterprise certificates are required.

For more information about the developer program, please see the following web site.

Install the Xcode

Xcode is available in the Mac App Store and xip versions. They have same functions. You can choose one of them with your needs. I use the Mac App Store version on my main machine to know that Xcode has been updated. When I need an old version of Xcode, I use xip version.

Compare two versions, the Mac App Store version takes longer time than xip version to update or install, so I use xip version on sub machines. Apple Silicon Macs have a shorter installation time compared to Intel Macs, but the Store version still takes longer than the xip version.

Mac App Store version

To install or update the Mac App Store version, use App Store app. It is simple. Automatically checks updates, you can know that it has been updated soon. On the other hand, there is a weakness, updates take time. Update when you have time to spare (it can take anywhere from 30 minutes to an hour).

Search for “Xcode” in the App Store app.

Xcode in the App Store
Xcode in the App Store

xip version

You can use xip version if you are member of the Apple Developer Program. The xip version can be downloaded from “More Downloads” page in the Apple Developer Site. You can also download old versions too.

Double click the downloaded xip file, the Xcode.app will be saved. Move it to the applications folder then the installation is completed.

Downloaded xip file
Downloaded xip file

Setup on first time

A license agreement dialog will appear when Xcode is launched for the first time or when updating the SDK, etc. You have to agree to the license in order to use Xcode and the iOS SDK. Please click the “Agree” button to accept the license.

Xcode and iOS SDK License Agreement dialog
Xcode and iOS SDK License Agreement dialog

If you agree, an authentication dialog will appear to begin installation of the required components. Enter the password of the logged-in user or authenticate with Touch ID. If the authentication is successful, the component will be installed.

Installing components
Installing components

The “Welcome” window is appeared when the installation is completed.

Welcome window
Welcome window

Sign in with Apple ID

Set the Apple ID to be used for development in Xcode as follows. If you have enrolled in the Apple Developer Program, use the Apple ID that you have enrolled with.

STEP
Select the “Preferences…” from the “Xcode” menu.
STEP
Open the “Accounts” tab.
STEP
Click the “+” button in the accounts list at left side of the window.
Accounts tab
Accounts tab
STEP
Select the “Apple ID” and click the “Continue” button.
Select the "Apple ID"
Select the “Apple ID”
STEP
Enter your Apple ID and click the “Next” button.
Enter your Apple ID
Enter your Apple ID
STEP
Enter your password and click “Next” button.
STEP
If the multi factor authentication dialog is displayed, follow to it and enter your one time pass code.
STEP
When you successfully sign in to your Apple ID, it will be displayed in the list.
Sign in successfully
Sign in successfully

List of Serials

This article is part of a series of articles titled “How to Use Xcode”. For other articles in the same series, please open the following links

How to use Xcode (List of Serials)

Let's share this post !

Author of this article

Akira Hayashiのアバター Akira Hayashi Representative, Software Engineer

I am an application developer loves programming. This blog is a tech blog, its articles are learning notes. In my work, I mainly focus on desktop and mobile application development, but I also write technical books and teach seminars. The websites of my work and books are here -> RK Kaihatsu.

TOC