Downloading and installing Xcode from the App Store
Before you begin writing iOS apps, you need to download and install Xcode from the App Store. Follow these steps:
- Choose App Store from the Apple menu.
- In the search field in the top-right corner, type
Xcode
and press the Return key. - You should see Xcode in the search results. Click Get and click Install.
- If you have an Apple ID, type it in the Apple ID textbox. If you don't have an Apple ID, click the Create Apple ID button and follow the step-by-step instructions to create one:
Important information
You can see more information on how to create an Apple ID at this link: https://support.apple.com/en-us/HT204316#appstore
- Once Xcode has been installed, launch it. You should see the following Welcome to Xcode screen. Click Create a new Xcode project in the left-hand pane:
- You will see the new project screen as follows. In the Choose a template for your new project: section, select iOS. Choose App and then click Next:
- You will now see the Choose options for your new project: screen:
Configure this options screen as follows:
- Product Name: The name of your app. Enter
ExploringXcode
in the text field. - Organization Identifier: Used to create a unique identifier for your app on the App Store. Normally, reverse DNS notation is used. Enter
com.yourname
for now. - Interface: The method used to create the user interface for your app. Set this to Storyboard.
- Language: The programming language to be used. Set this to Swift.
Leave the other settings at their default values. Make sure all the checkboxes are unticked. Click Next when done.
- Product Name: The name of your app. Enter
- You'll now see a Save dialog box. Choose a location to save your project, such as the
Desktop
orDocuments
folder, and then click Create: - If you see a dialog box saying No author information was supplied by the version control system, click Fix.
Important information
The reason why you see this dialog box is because the Source Control checkbox is ticked. Apple recommends that Source Control be turned on. To learn more about version control and Git, refer to the following link: https://git-scm.com/video/what-is-version-control
- You will see the Source Control preference screen as follows:
Enter the following information:
- Author Name: Your own name
- Author Email: Your email address
Close the Source Control preference screen by clicking the red button in the top-left corner when done.
- The Xcode main window will appear.
Fantastic! You have now successfully downloaded and installed Xcode and created your first project. In the next section, you will learn about the Xcode user interface.