Mapbox Studio style rollback after a failed upgrade: what actually carries over to clients?
0 reputation · 16 Jun 2026, 02:31 UTC
0 reputation · 16 Jun 2026, 02:31 UTC
Mapbox Studio keeps a version history for each published style and offers a Revert/Restore option in the style editor. The scenario I am planning for is a style upgrade that introduces breaking changes to the style JSON, where rolling back to the previous published version is the recovery path.
The documentation and practical behavior leave a few points unclear for me. Reverting restores the prior style's source data, tileset references, and layout, but it appears not to affect map instances already loaded in client applications, and client SDKs seem to require a republish or forced style refresh to pick up the reverted version. I am also unsure how the version retention window (reportedly around 30 days) and the pre-2020 style migration requirement constrain whether a rollback is even possible when an upgrade fails weeks later.
My questions:
After you roll back a style in Mapbox Studio, already‑running map instances (Mapbox GL JS, Android SDK, iOS SDK) continue to display the style that was loaded when the map was created. They do not automatically pick up the reverted version until they request a fresh style load.
GET /styles/{style_id} returns the restored JSON, and GET /styles/{style_id}/versions shows the new version as the latest with identical content to the restored style.Mapbox GL JS and the mobile SDKs load the style once at map initialization and keep it in memory. Subsequent tile requests reference the already‑loaded style JSON, so a server‑side change (including a rollback) does not propagate unless the client explicitly asks for the style again.
map.setStyle(styleURL) again, or append a cache‑busting query string (e.g., styleURL + '?v=' + Date.now()) to force a fresh fetch.mapView.getMapAsync { map -> map.setStyle(styleURL) } or recreate the MapView with the same style URL.mapView.styleURL = styleURL or mapView.setStyleURL(styleURL) to trigger a reload.GET https://api.mapbox.com/styles/v1/{username}/{style_id}?access_token=YOUR_TOKEN before and after the rollback; the returned JSON should match the pre‑upgrade style.GET https://api.mapbox.com/styles/v1/{username}/{style_id}/versions?access_token=YOUR_TOKEN and confirm that the newest version number has incremented and its created timestamp corresponds to the rollback time.If you are using offline packs or pre‑cached tile bundles, a simple style reload may not update the displayed tiles; you would need to clear or regenerate those offline packs. Let me know whether you rely on offline data so I can advise on the additional step.
Use comments to ask for clarification. Post a solution as an answer.
No question comments on this page.