Code Samples

Select platform: Android iOS JavaScript

Sample apps demonstrating the features of the Maps JavaScript API are listed below for quick reference. For samples that include step-by-step walkthoughs, see our tutorials.

Basics

Events

Controls and Interaction

Customize a Map

Data-driven styling for boundaries

Data-driven styling for datasets

Web Components

Add markers to the Map

Advanced Markers

Markers (Legacy)

Draw on the Map

Layers

Vector Map Features

3D Maps (Experimental)

MapTypes

Services

Directions (Legacy)

Distance Matrix (Legacy)

Libraries: Drawing

Libraries: Geometry

Address Validation

Places (New)

Places UI Kit

Places Service (Legacy)

React Google Maps Library

Fun