Select platform: [Android](https://developers.google.com/maps/documentation/android-sdk/cloud-customization/json.md.txt "View this page for the Android platform docs.") [Android 3D](https://developers.google.com/maps/documentation/maps-3d/android-sdk/cloud-customization/json.md.txt "View this page for the Android 3D platform docs.") [iOS](https://developers.google.com/maps/documentation/ios-sdk/cloud-customization/json.md.txt "View this page for the iOS platform docs.") [iOS 3D](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/cloud-customization/json.md.txt "View this page for the iOS 3D platform docs.") [JavaScript](https://developers.google.com/maps/documentation/javascript/cloud-customization/json.md.txt "View this page for the JavaScript platform docs.") [Web Service](https://developers.google.com/maps/documentation/maps-static/cloud-customization/json.md.txt "View this page for the Web Service platform docs.")

<br />

This document explains how to use JSON to create, edit, and export map styles.
For information on what you can style using JSON, see the
[JSON reference for cloud-based maps styling](https://developers.google.com/maps/documentation/ios-sdk/cloud-customization/json-reference.md.txt).

## Import a JSON map style

To create a map style using JSON, perform the following steps:

1. In the Google Cloud console,
   go to [**Map styles**](https://console.cloud.google.com/google/maps-apis/studio/styles), and select a project, if needed.

2. In **Map styles** , click **Create style**.

3. In the dialog, select the **JSON** tab.

4. There are two ways to import your JSON style:

   - Paste your valid JSON styling code into the field, or
   - Click **Upload JSON File** and choose a local JSON file to use. The JSON styling code appears in the field.

   > [!NOTE]
   > **Note:** When importing legacy JSON, a warning appears and the style is converted to the latest JSON format. The conversion is approximate but sets you up for a richer and more customizable experience. To only use legacy JSON, see [Use embedded JSON style declarations](https://developers.google.com/maps/documentation/ios-sdk/styling.md.txt).

5. Check whether your JSON has errors.

   - If your JSON has errors, the warning "Your JSON contains N errors" appears and you can expand the warning to learn more.
   - If your JSON is valid, the map preview shows your custom style and the blue **Customize** button is available.
6. Click **Customize** to create a new map style.

7. In your new map style, select map features and review or change their style
   as needed. Map features with custom styles have a solid blue dot next to
   them.

   > [!NOTE]
   > **Note:** Not all styles appear at all zoom levels.

8. Click **Save**.

9. In the **Save and publish map style** box, enter a name for your style and
   optionally a description, and click **Save**.

The style is automatically published, and you see your new style's
main page.

To add your map style to a map ID, see
[Associate your style to a map ID](https://developers.google.com/maps/documentation/ios-sdk/cloud-customization/map-styles.md.txt#associate-style-with-map-id).

## Edit a map style with JSON

You can edit map styles using the JSON tab in the style editor.

To edit a map style using JSON, see the following steps:

1. In the Google Cloud console,
   go to [**Map styles**](https://console.cloud.google.com/google/maps-apis/studio/styles), and select a project, if needed.

2. In **Map styles**, select an existing style from the style list.

3. In the style's main page, select **Customize**.

4. Select the **JSON** tab to open the JSON style editor.

5. Make your changes in the editor. You can also upload a JSON file.

6. Click **Apply** to update the style panel and preview map.

   > [!NOTE]
   > **Note:** When you change a map feature in the style panel, it updates the JSON code automatically.

7. Once you're done with all of your changes, click **Save** . If you're
   creating a new style, the changes go live automatically. If you're making
   changes to an existing style, the changes save as a draft and you must click
   **Publish** to have your changes go live for any map IDs using that map
   style.

## Export a map style as JSON

To export a map style as a JSON file, see the following steps:

1. In the Google Cloud console,
   go to [**Map styles**](https://console.cloud.google.com/google/maps-apis/studio/styles), and select a project, if needed.

2. In **Map styles**, select an existing style from the style list.

3. In the style's main page, select **Customize**.

4. Select the **JSON** tab to open the JSON style editor.

5. Select **Export**.

> [!NOTE]
> **Note:** Some options from the **Map Settings** menu won't be included in the exported JSON. See [JSON reference](https://developers.google.com/maps/documentation/ios-sdk/cloud-customization/json-reference.md.txt#limitations).