Stay organized with collections Save and categorize content based on your preferences.
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 are available for each release.
Step 1: Install the required softwareTo build a project using the Places SDK for iOS, you need:
The Places SDK for iOS can be installed via Swift Package Manager. To add the SDK, ensure you have removed any existing Places SDK for iOS dependencies.
Important: These instructions assume the use of Xcode 15 or later, but should be similar for previous versions of Xcode.To add the SDK to a new or existing project, follow these steps:
project
or workspace
, then go to File > Add Package Dependencies.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".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.
To update the package
for an existing project, follow these steps:
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.
To remove existing Places SDK for iOS installed manually, follow these steps:
GooglePlaces.xcframework
GooglePlacesSwift.xcframework
GooglePlaces
bundle.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. You can choose to add Places SDK for iOS, Places Swift SDK for iOS, or both.
GooglePlaces.xcframework
GooglePlacesSwift.xcframework
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.
CoreGraphics.framework
CoreLocation.framework
libc++.tbd
libz.tbd
QuartzCore.framework
UIKit.framework
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.
The Places SDK for iOS and Places Swift SDK for iOS are available as CocoaPod pods, GooglePlaces and GooglePlacesSwift.
CocoaPods is an open source dependency manager for Swift and Objective-C Cocoa projects. If you don't already have the CocoaPods tool, install it on macOS by running the following command from the terminal. For details, see the CocoaPods Getting Started guide.
sudo gem install cocoapods
Create a Podfile
to install the SDKs and their dependencies:
Podfile
in your project directory. This file defines your project's dependencies.Podfile
and add your dependencies along with their versions. Here is an example that specifies your application target name, and the names of the GooglePlaces
and GooglePlacesSwift
pods:
source 'https://github.com/CocoaPods/Specs.git' platform :ios, '16.0' target 'YOUR_APPLICATION_TARGET_NAME_HERE' do pod 'GooglePlaces', '10.1.0' pod 'GooglePlacesSwift', '10.1.0' endMake sure to regularly run
pod outdated
to detect when there is a newer version to ensure you're always on the latest.Podfile
.Open a terminal and go to the directory containing the Podfile
:
cd <path-to-project>
Run the pod install
command. This will install the APIs specified in the Podfile
, along with any dependencies they may have.
pod install
Close Xcode, and then open (double-click) your project's .xcworkspace
file to launch Xcode. From this time onwards, you must use the .xcworkspace
file to open the project.
To update the API for an existing project, follow these steps:
Podfile
.pod update
command. This will update all of the APIs specified in the Podfile
to the latest version.In the following examples, replace YOUR_API_KEY
with your API key.
Add your API key to your AppDelegate.swift
as follows:
import GooglePlacesSwift
application(_:didFinishLaunchingWithOptions:)
method, replacing YOUR_API_KEY with your API key:
PlacesClient.provideAPIKey("YOUR_API_KEY")
Add your API key to your AppDelegate.swift
as follows:
import GooglePlaces
application(_:didFinishLaunchingWithOptions:)
method, replacing YOUR_API_KEY with your API key:
GMSPlacesClient.provideAPIKey("YOUR_API_KEY")
Add your API key to your AppDelegate.m
as follows:
@import GooglePlaces;
application:didFinishLaunchingWithOptions:
method, replacing YOUR_API_KEY with your API key:
[GMSPlacesClient provideAPIKey:@"YOUR_API_KEY"];
Apple requires app privacy details for apps on the App Store. Visit the Apple App Store Privacy Details page 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 from the archive.
Next stepsExcept as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-08-14 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-14 UTC."],[[["After enabling billing and creating an API key, set up an Xcode project with Xcode version 15.0 or later to develop your app using the Places SDK for iOS."],["Install the Places SDK for iOS using Swift Package Manager, CocoaPods, or manual installation, following the detailed steps provided for each method."],["Add your API key to your app's AppDelegate file (Swift, Objective-C, or GooglePlacesSwift) using the provided code snippets and replacing \"YOUR_API_KEY\" with your actual key."],["Optionally, for App Store deployment, inspect the Apple Privacy Manifest file included in the SDK's resources bundle to ensure compliance with Apple's privacy requirements."]]],["To set up the Places SDK for iOS, first ensure you have Xcode 15.0 or later. Then, install the SDK using Swift Package Manager, CocoaPods, or manual installation. For Swift Package Manager, add the SDK URL to your Xcode project and select the desired package. For manual installs, download and add the XCFramework files and resources, and link necessary frameworks and libraries in the project's build settings. For CocoaPods, create a `Podfile` specifying the `GooglePlaces` and `GooglePlacesSwift` pods and run `pod install`. Lastly, add your API key to your `AppDelegate` file.\n"]]
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4