After you enable billing and create an API key, you're ready to set up the
Xcode project that you use to develop your app.

[Release notes](https://developers.google.com/maps/documentation/places/ios-sdk/releases) are available for each
release.

## Step 1: Install the required software

To build a project using the Places SDK for iOS, you need:

- [Xcode](https://developer.apple.com/xcode/) **version 26.0** or later

## Step 2: Create the Xcode project and install the Places SDK for iOS

### Swift Package Manager


The Places SDK for iOS can be installed via [Swift Package Manager](https://developer.apple.com/documentation/xcode/swift-packages). To add the SDK, ensure you have
removed any existing Places SDK for iOS dependencies.


To add the SDK to a new or existing project, follow these steps:

1. Open your Xcode `project` or `workspace`, then go to **File \> Add Package Dependencies**.
2. Enter <https://github.com/googlemaps/ios-places-sdk> as the URL, press **Enter** to pull in the package, and click "Add Package".
3. To install a specific `version`, set the **Dependency Rule** field to one of the version-based options. For new projects, we recommend specifying the latest version and using the "Exact Version" option. Once complete, click "Add Package".
4. From the **Choose Package Products** window, verify that `GooglePlaces`, `GooglePlacesSwift`, or both, will be added to your designated main target. Once complete, click **Add Package** .

   #### If you are updating Google Places Swift from the deprecated GitHub URL

   **Important:** The GitHub URL to access Google Places Swift has changed starting with version 0.3.0. If you are updating a version of GooglePlacesSwift that was accessed through the old URL, `https://github.com/googlemaps/ios-places-swift-sdk`, remove it from your Xcode's package dependencies section.
5. To verify your installation, navigate to your target's **General** pane. In **Frameworks, Libraries, and Embedded Content** , you should see the installed packages. You can also view the **Package Dependencies** section of **Project Navigator** to verify the package and its version.

To update the `package` for an existing project, follow these steps:

1. From Xcode, go to **File \> Packages \> Update To Latest Package Versions** .

   #### If you are updating Google Places Swift from the deprecated GitHub URL

   **Important:** The GitHub URL to access Google Places Swift has changed starting with version 0.3.0. If you are updating a version of GooglePlacesSwift that was accessed through the old URL, `https://github.com/googlemaps/ios-places-swift-sdk`, remove it from your Xcode's package dependencies section.
2. To verify your installation, go to the **Package Dependencies** section of **Project Navigator** to verify the package and its version.

**Important:** Sometimes, artifacts cannot be resolved or errors can occur, in this case select "File \> Packages \> Reset Package Cache".

<br />

<br />


To remove existing Places SDK for iOS installed manually,
follow these steps:

1. From your Xcode project configuration settings, find **Frameworks, Libraries,
   and Embedded Content** . Use the **minus sign(-)** to remove the following frameworks:
   - `GooglePlaces.xcframework`
   - `GooglePlacesSwift.xcframework`
2. From the top level directory of your Xcode project, remove the `GooglePlaces` bundle.

### Manual installation

This guide shows how to manually add the XCFrameworks containing the Places SDK for iOS and Places Swift SDK for iOS to your
project and configure your build settings in Xcode. An XCFramework is a binary package that you can use on multiple platforms, including machines
using [Apple silicon](https://support.apple.com/en-us/HT211814). You can choose to add Places SDK for iOS, Places Swift SDK for iOS, or both.

1. Download the following SDK binary and resource files:
   - [GooglePlaces](https://dl.google.com/geosdk/swiftpm/11.3.0/GooglePlaces_3p.xcframework.zip)
   - [GooglePlacesResources](https://dl.google.com/geosdk/swiftpm/11.3.0/GooglePlacesResources.zip)
2. If you are installing Places Swift SDK for iOS, install the following files:
   - [GooglePlacesSwift](https://dl.google.com/geosdk/swiftpm/11.3.0/google_places_swift.xcframework.zip)
   - [GooglePlacesSwiftResources](https://dl.google.com/geosdk/swiftpm/11.3.0/GooglePlacesSwiftResources.zip)
3. Extract the files to access the XCFramework and resources.
4. Launch Xcode and either open an existing project, or create a new project. If you're newer to iOS development, create a new project and select the **iOS App template**.
5. Remove any Maps bundles from previous releases from your project.
6. Open the **General** tab. Drag the following XCFramework into your project under **Frameworks, Libraries, and Embedded Content** . Make sure to select **Do Not Embed** :
   - `GooglePlaces.xcframework`

   If you are installing Places Swift SDK, drag the following XCFramework into your project under **Frameworks, Libraries, and Embedded Content** . Make sure to select **Do Not Embed** :
   - `GooglePlacesSwift.xcframework`
7. Copy the `GooglePlaces.bundle` from the **GooglePlacesResources** you downloaded into your Xcode project's top level directory. Make sure to select **Copy items into destination group's folder** when prompted.   

   If you are installing Places Swift SDK, copy the `GooglePlacesSwift.bundle` from the **GooglePlacesSwiftResources** you downloaded into your Xcode project's top level directory. Make sure to select **Copy items into destination group's folder** when prompted.
8. Select your project from the Project Navigator, and choose your application's target.
9. Open the **Build Phases** tab. Within **Link Binary with
   Libraries** , add the following frameworks and libraries:
   - `CoreGraphics.framework`
   - `CoreLocation.framework`
   - `libc++.tbd`
   - `libz.tbd`
   - `QuartzCore.framework`
   - `UIKit.framework`
10.
    Choose your project, rather than a specific target, and open the
    **Build Settings** tab. In the **Linking - General -\> Other Linker
    Flags** section, add `-ObjC` to "Debug" and "Release". If these
    settings aren't visible, change the filter in the **Build Settings** bar
    from **Basic** to **All**.

## Step 3: Add the API key to your app

In the following examples, replace `YOUR_API_KEY` with your API key.
GooglePlacesSwift

Add your API key to your `AppDelegate.swift` as follows:

- Add the following import statement:

  ```
  import GooglePlacesSwift
  ```
- Add the following to your `application(_:didFinishLaunchingWithOptions:)` method, replacing *YOUR_API_KEY* with your API key:

  ```
  PlacesClient.provideAPIKey("YOUR_API_KEY")
  ```

### Swift

Add your API key to your `AppDelegate.swift` as follows:

- Add the following import statement:

  ```swift
  import GooglePlaces
  ```
- Add the following to your `application(_:didFinishLaunchingWithOptions:)` method, replacing *YOUR_API_KEY* with your API key:

  ```swift
  GMSPlacesClient.provideAPIKey("YOUR_API_KEY")
  ```

### Objective-C

Add your API key to your `AppDelegate.m` as follows:

- Add the following import statement:

  ```objective-c
  @import GooglePlaces;
  ```
- Add the following to your `application:didFinishLaunchingWithOptions:` method, replacing *YOUR_API_KEY* with your API key:

  ```objective-c
  [GMSPlacesClient provideAPIKey:@"YOUR_API_KEY"];
  ```

## Step 4 (optional): Inspect Apple Privacy Manifest file

> [!NOTE]
> **Note:** The following is relevant when you deploy your app to the web store.

Apple requires app privacy details for apps on the App Store. Visit the [Apple App Store Privacy Details page](https://developers.google.com/maps/documentation/ios-sdk/apple-privacy-policy.md.txt) for updates and more information.

The Apple Privacy Manifest file is included in the resources bundle for the SDK. To verify that the Privacy Manifest File has been included, and to inspect its contents, create an archive of your app and [generate a privacy report](https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests#4239187) from the archive.

## Next steps

- Start writing code. A recommended starting point is implementing a starter app that get the [user's current place](https://developers.google.com/maps/documentation/places/ios-sdk/current-place).
- After your project is configured, you can explore the [sample apps](https://developers.google.com/maps/documentation/places/ios-sdk/examples.md.txt).
- [Use App Check to secure your API key](https://developers.google.com/maps/documentation/places/ios-sdk/app-check.md.txt).