> For the complete documentation index, see [llms.txt](https://docs.mapbox.com/ja/style-spec/llms.txt)

# Root

Root level properties of a Mapbox style specify the map's layers, tile sources and other resources, and default values for the initial camera position when not specified elsewhere.

```json
{
  "version": 8,
  "name": "Mapbox Streets",
  "sprite": "mapbox://sprites/mapbox/streets-v{{ref.$version}}",
  "glyphs": "mapbox://fonts/mapbox/{fontstack}/{range}.pbf",
  "sources": {...},
  "layers": [...]
}
```

There are some root level properties, including `owner` and `modified`, that are not documented here because they do not affect how a style is rendered. For the full list of these properties and their descriptions, see the [example style object](https://docs.mapbox.com/api/maps/styles/#the-style-object) in the Mapbox Styles API documentation.

### layers

Required [array](https://docs.mapbox.com/ja/ja/style-spec/reference/types/#array) of [layers](https://docs.mapbox.com/ja/ja/style-spec/reference/layers/) .

Layers will be drawn in the order of this array.

```json
[
  {
    "id": "water",
    "source": "mapbox-streets",
    "source-layer": "water",
    "type": "fill",
    "paint": {
      "fill-color": "#00ffff"
    }
  }
]
```

### sources

Required object with [source](https://docs.mapbox.com/ja/ja/style-spec/reference/sources/) values .

Data source specifications.

```json
{
  "mapbox-streets": {
    "type": "vector",
    "url": "mapbox://mapbox.mapbox-streets-v6"
  }
}
```

### version

Required [enum](https://docs.mapbox.com/ja/ja/style-spec/reference/types/#enum) .

Style specification version number. Must be 8.

```json
8
```

### bearing

Optional [number](https://docs.mapbox.com/ja/ja/style-spec/reference/types/#number) . Units in degrees. Defaults to `0`.

Default bearing, in degrees. The bearing is the compass direction that is "up"; for example, a bearing of 90° orients the map so that east is up. This value will be used only if the map has not been positioned by other means (e.g. map options or user interaction).

```json
29
```

### camera

Optional [camera](https://docs.mapbox.com/ja/ja/style-spec/reference/types/#camera) .

Global setting to control additional camera intrinsics parameters, e.g. projection type (perspective / orthographic).

### center

Optional [array](https://docs.mapbox.com/ja/ja/style-spec/reference/types/#array) of [numbers](https://docs.mapbox.com/ja/ja/style-spec/reference/types/#number) .

Default map center in longitude and latitude. The style center will be used only if the map has not been positioned by other means (e.g. map options or user interaction).

```json
[
  -73.9749,
  40.7736
]
```

### color-theme

Optional [colorTheme](https://docs.mapbox.com/ja/ja/style-spec/reference/types/#colorTheme) .

A global modifier for the colors of the style.

### featuresets

EXPERIMENTAL

Optional [featuresets](https://docs.mapbox.com/ja/style-spec/reference/featuresets) .

Defines sets of features for querying, interaction, and state management on the map, referencing individual layers or subsets of layers within the map's style.

```json
{
  "poi": {
    "selectors": [
      {
        "layer": "poi",
        "properties": {
          "type": [
            "get",
            "type"
          ],
          "name": [
            "get",
            "name"
          ],
          "brand": "ABC"
        }
      }
    ]
  }
}
```

| SDK Support | Mapbox GL JS | Android SDK | iOS SDK |
| --- | --- | --- | --- |
| basic functionality | >= 3.9.0 | >= 11.9.0 | >= 11.9.0 |

### fog

Optional [fog](https://docs.mapbox.com/ja/ja/style-spec/reference/fog/) .

A global effect that fades layers and markers based on their distance to the camera. The fog can be used to approximate the effect of atmosphere on distant objects and enhance the depth perception of the map when used with terrain or 3D features. Note: fog is renamed to atmosphere in the Android and iOS SDKs and planned to be changed in GL-JS v.3.0.0.

### fragment

Optional [boolean](https://docs.mapbox.com/ja/ja/style-spec/reference/types/#boolean) .

Indicates that a style is a fragment style.

```json
true
```

### glyphs

Optional [string](https://docs.mapbox.com/ja/ja/style-spec/reference/types/#string) . Defaults to `"mapbox://fonts/mapbox/{fontstack}/{range}.pbf"`.

A URL template for loading signed-distance-field glyph sets in PBF format. The URL must include `{fontstack}` and `{range}` tokens. This property is required if any layer uses the `text-field` layout property. The URL must be absolute, containing the [scheme, authority and path components](https://en.wikipedia.org/wiki/URL#Syntax).

```json
"mapbox://fonts/mapbox/{fontstack}/{range}.pbf"
```

### iconsets

EXPERIMENTAL

Optional [iconsets](https://docs.mapbox.com/ja/ja/style-spec/reference/types/#iconsets) .

A collection of icon sets

| SDK Support | Mapbox GL JS | Android SDK | iOS SDK |
| --- | --- | --- | --- |
| basic functionality | >= 3.11.0 | >= 11.11.0 | >= 11.11.0 |

### imports

Optional [array](https://docs.mapbox.com/ja/ja/style-spec/reference/types/#array) of style [imports](https://docs.mapbox.com/ja/ja/style-spec/reference/imports/) .

Imports other styles into this style.

| SDK Support | Mapbox GL JS | Android SDK | iOS SDK |
| --- | --- | --- | --- |
| basic functionality | >= 3.0.0 | >= 11.0.0 | >= 11.0.0 |

### light

Optional [light](https://docs.mapbox.com/ja/ja/style-spec/reference/light/) .

The global light source. Note: This API is deprecated. Prefer using `flat` light type instead in the `lights` API.

```json
{
  "anchor": "viewport",
  "color": "white",
  "intensity": 0.4
}
```

### lights

Optional [array](https://docs.mapbox.com/ja/ja/style-spec/reference/types/#array) of [3D light](https://docs.mapbox.com/ja/ja/style-spec/reference/light/#3d-lighting)s .

Array of light sources affecting the whole map and the default for 3D style, mutually exclusive with the light property

```json
[
  {
    "id": "environment",
    "type": "ambient",
    "properties": {
      "color": "rgba(255.0, 0.0, 0.0, 1.0)",
      "intensity": 0.4
    }
  },
  {
    "id": "sun_light",
    "type": "directional",
    "properties": {
      "color": "rgba(255.0, 0.0, 0.0, 1.0)",
      "intensity": 0.4,
      "direction": [
        200,
        40
      ],
      "cast-shadows": true,
      "shadow-intensity": 0.2
    }
  }
]
```

| SDK Support | Mapbox GL JS | Android SDK | iOS SDK |
| --- | --- | --- | --- |
| basic functionality | >= 3.0.0 | >= 11.0.0 | >= 11.0.0 |

### metadata

Optional * .

Arbitrary properties useful to track with the stylesheet, but do not influence rendering. Properties should be prefixed to avoid collisions, like 'mapbox:'.

### models

Optional [models](https://docs.mapbox.com/ja/ja/style-spec/reference/types/#models) .

Specification of models used in the style.

```json
{
  "spruce1-lod0": "asset://spruce1-lod0.glb",
  "spruce1-lod1": "asset://spruce1-lod1.glb",
  "spruce1-lod2": "asset://spruce1-lod2.glb"
}
```

### name

Optional [string](https://docs.mapbox.com/ja/ja/style-spec/reference/types/#string) .

A human-readable name for the style.

```json
"Bright"
```

### pitch

Optional [number](https://docs.mapbox.com/ja/ja/style-spec/reference/types/#number) . Units in degrees. Defaults to `0`.

Default pitch, in degrees. Zero is perpendicular to the surface, for a look straight down at the map, while a greater value like 60 looks ahead towards the horizon. The style pitch will be used only if the map has not been positioned by other means (e.g. map options or user interaction).

```json
50
```

### projection

Optional [projection](https://docs.mapbox.com/ja/ja/style-spec/reference/projection/) .

The projection the map should be rendered in. Supported projections are Mercator, Globe, Albers, Equal Earth, Equirectangular (WGS84), Lambert conformal conic, Natural Earth, and Winkel Tripel. Terrain, sky and fog are supported by only Mercator and globe. CustomLayerInterface is not supported outside of Mercator.

```json
{
  "name": "albers",
  "center": [
    -154,
    50
  ],
  "parallels": [
    55,
    65
  ]
}
```

### rain

EXPERIMENTAL

Optional [rain](https://docs.mapbox.com/ja/ja/style-spec/reference/rain/) .

Global precipitation particle-based rain effect. Having rain present in the style forces constant map repaint mode.

### schema

Optional [schema](https://docs.mapbox.com/ja/ja/style-spec/reference/schema/#schema) .

Definition of the schema for configuration options.

| SDK Support | Mapbox GL JS | Android SDK | iOS SDK |
| --- | --- | --- | --- |
| basic functionality | >= 3.0.0 | >= 11.0.0 | >= 11.0.0 |

### snow

EXPERIMENTAL

Optional [snow](https://docs.mapbox.com/ja/ja/style-spec/reference/snow/) .

Global precipitation particle-based snow. Having snow present in the style forces constant map repaint mode

### sprite

Optional [string](https://docs.mapbox.com/ja/ja/style-spec/reference/types/#string) .

A base URL for retrieving the sprite image and metadata. The extensions `.png`, `.json` and scale factor `@2x.png` will be automatically appended. This property is required if any layer uses the `background-pattern`, `fill-pattern`, `line-pattern`, `fill-extrusion-pattern`, or `icon-image` properties. The URL must be absolute, containing the [scheme, authority and path components](https://en.wikipedia.org/wiki/URL#Syntax).

```json
"mapbox://sprites/mapbox/bright-v8"
```

### terrain

Optional [terrain](https://docs.mapbox.com/ja/ja/style-spec/reference/terrain/) .

A global modifier that elevates layers and markers based on a DEM data source.

### transition

Optional [transition](https://docs.mapbox.com/ja/ja/style-spec/reference/transition/) .

A global transition definition to use as a default across properties, to be used for timing transitions between one value and the next when no property-specific transition is set. Collision-based symbol fading is controlled independently of the style's `transition` property.

```json
{
  "duration": 300,
  "delay": 0
}
```

### zoom

Optional [number](https://docs.mapbox.com/ja/ja/style-spec/reference/types/#number) .

Default zoom level. The style zoom will be used only if the map has not been positioned by other means (e.g. map options or user interaction).

```json
12.5
```