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

# style-optimized vector tiles

**Style-optimized vector tiles** remove any layers or features in a tile that are not represented by a given Mapbox [style](https://docs.mapbox.com/help/ja/glossary/style/). Style-optimized vector tiles are smaller than tiles that are not style-optimized and can reduce the size of offline caches.

For example, say you have a style that references a tileset with four layers: campsites, mountains, forestland, and buildings. The final map includes [icons](https://docs.mapbox.com/help/ja/glossary/icon/) for campsites, a pattern for forests, and a pattern for blue mountains, but does not use buildings. In a normal Mapbox map, the tiles loaded include all four layers even though they aren't all needed. A style-optimized vector tile includes only campsites, forestland, and blue mountains. It removes unused layers and features based on attributes and zoom levels.

![illustration comparing normal vector tilesets on the left and style-optimized vector tilesets on the right](https://docs.mapbox.com/help/ja/assets/ideal-img/style-optimized-illustration.d34bab6.480.png)

Style-optimized vector tiles are available through the [Mapbox Vector Tiles API](https://docs.mapbox.com/api/maps/vector-tiles/). In a Vector Tiles API request, you can request style-optimized tiles by adding the `style` parameter:

```bash
https://api.mapbox.com/v4/mapbox.mapbox-streets-v8/12/1171/1566.mvt?style=mapbox://styles/mapbox/streets-v12@00&access_token=YOUR_MAPBOX_ACCESS_TOKEN
```

You can use style-optimized vector tilesets in [Mapbox GL JS](https://docs.mapbox.com/mapbox-gl-js/) by adding `?optimize=true` to the end of your style URL:

```js
const map = new mapboxgl.Map({
  container: 'map',
  style:
    'mapbox://styles/mapbox/outdoors-v12?optimize=true' // optimize=true
});
```

You should *not* use `?optimize=true` if you plan to add any style layers at runtime that rely on a source layer that is in a tileset that is defined as a source in the style JSON, *but* not used in the initial style.

For example, if your application uses the Mapbox Streets v11 style (which includes the tilesets `mapbox.mapbox-streets-v8` and `mapbox.mapbox-terrain-v2`) and you want to add contour lines client-side based on a user's preference, you should *not* use style-optimized vector tiles. Because the `contour` source layer is not used in the Mapbox Streets v11 style when it is initially loaded, it will not be available as a `source-layer` when adding to a new "Contours" layer to the style.

**Related resources:**

-   [Mapbox Vector Tiles API documentation](https://docs.mapbox.com/api/maps/#retrieve-vector-tiles)
-   [Mapbox GL JS `Map` object documentation](https://docs.mapbox.com/mapbox-gl-js/api/#map)