Samples demonstrating how to use Maps SDK for Android.
This repo contains the following samples:
- ApiDemos: A collection of small demos showing most features of the Maps SDK for Android.
- WearOS: Displays a map on a Wear OS device. This sample demonstrates the basic setup required for a gradle-based Android Studio project.
- Tutorials: Samples associated with tutorials in the developer's guide. See each sample for a link to the associated guide.
- Snippets: Snippets for code found in https://developers.google.com/maps/documentation/android-sdk
To run the samples, you will need:
- To sign up with Google Maps Platform
- A Google Maps Platform project with the Maps SDK for Android enabled
- An API key associated with the project above ... follow the API key instructions if you're new to the process
- See each sample for pre-requisites.
- All require up-to-date versions of the Android build tools and the Android support repository.
- Download the samples by cloning this repository
- In the welcome screen of Android Studio, select "Open an Existing project"
- Select one of the sample directories from this repository
Alternatively, use the gradlew build
command to build the project directly or download an APK
under releases.
Contributions are welcome and encouraged! If you'd like to contribute, send us a pull request and refer to our code of conduct and contributing guide.
This sample uses Google Maps Platform services. Use of Google Maps Platform services through this sample is subject to the Google Maps Platform Terms of Service.
This sample is not a Google Maps Platform Core Service. Therefore, the Google Maps Platform Terms of Service (e.g. Technical Support Services, Service Level Agreements, and Deprecation Policy) do not apply to the code in this sample.
This sample is offered via an open source license. It is not governed by the Google Maps Platform Support Technical Support Services Guidelines, the SLA, or the Deprecation Policy. However, any Google Maps Platform services used by the sample remain subject to the Google Maps Platform Terms of Service.
If you find a bug, or have a feature request, please file an issue on GitHub. If you would like to get answers to technical questions from other Google Maps Platform developers, ask through one of our developer community channels. If you'd like to contribute, please check the contributing guide.
You can also discuss this sample on our Discord server.