Overview
Mapbox is an interactive mapping platform used by developers as a programmable alternative to Google Maps. The Mapbox GL JS library renders vector tile maps in the browser using WebGL, providing customizable map experiences for location-based applications.
What This Script Does
The Mapbox GL JS library is a substantial JavaScript package that renders interactive vector maps directly in the browser using WebGL. When loaded, it:
- Fetches map tiles: Makes requests to Mapbox's tile servers (
api.mapbox.com) to download vector tile data, sprites, and fonts as the user pans and zooms the map. Each tile request includes the site's Mapbox access token. - Geolocation (optional): If the site uses the GeolocateControl, the browser's Geolocation API is invoked, which requires the user's permission via the browser's native prompt.
- Telemetry: Mapbox collects anonymized usage data (map loads, interactions) for billing and service improvement. This telemetry is sent to Mapbox's
events.mapbox.comendpoint and includes the access token, map interaction events, and a session identifier. Telemetry can be disabled viamapboxgl.accessTokenconfiguration or by settingmapboxgl.config.collectResourceTiming = false. - No cookies: Mapbox GL JS does not set cookies on the embedding site's domain. It uses the access token for authentication and billing rather than cookie-based tracking.
The library is large (approximately 200-700KB depending on version and plugins) and makes numerous network requests for tile data during map interaction.
Consent & Compliance
Mapbox is a functional tool — it provides interactive map content that is typically core to the page's purpose (store locators, delivery tracking, property search, etc.).
Under GDPR/ePrivacy:
- Map rendering: Functional and does not require consent when the map is integral to the service.
- Telemetry: The anonymized usage telemetry sent to Mapbox is a gray area. It transmits interaction data to a third party, but it is anonymized and used for service operation. Strict interpretations of ePrivacy may require consent for this telemetry.
- Geolocation: Handled by the browser's native permission prompt, separate from cookie consent.
Under CCPA, the IP addresses transmitted with tile requests may constitute personal information, but Mapbox acts as a service provider in this context.
Should You Block This Without Consent?
No. Mapbox is a functional content component that does not set cookies or perform cross-site tracking. If maps are integral to your site's functionality, they can load without consent. If you want to be strictly compliant, consider disabling Mapbox's telemetry endpoint, which removes the only data-sharing concern.
Is Mapbox GDPR compliant?
Mapbox typically loads functional trackers, which are not strictly necessary for your site to work. Under the GDPR and the ePrivacy Directive, non-essential cookies and trackers must stay blocked until a visitor gives clear opt-in consent. So Mapbox can be fully GDPR compliant, but only if your site holds its scripts until consent is granted and lets visitors decline just as easily. Compliance depends on how your site loads Mapbox, not on Mapbox itself.
Consent Categories
Also Known As
Industries
Tracked Domains (4)
Mapbox's trackers are occasionally seen, seen on under 1% of the sites ConsentStack has scanned. Scan your own site to see which of these are firing before consent.
mapbox.comEssentialmapbox.com is an essential domain operated by Mapbox, used to keep the site working, including security, load balancing, and sessions. Seen on under 1% of scanned sites.
api.mapbox.comFunctionalapi.mapbox.com is a functional domain operated by Mapbox, used to run site features like chat, video, embeds, and preferences.
tiles.mapbox.comFunctionaltiles.mapbox.com is a functional domain operated by Mapbox, used to run site features like chat, video, embeds, and preferences.
events.mapbox.comFunctionalevents.mapbox.com is a functional domain operated by Mapbox, used to run site features like chat, video, embeds, and preferences.
Frequently Asked Questions
Related Vendors

Manage consent for Mapbox
ConsentStack automatically detects and manages Mapbox trackers so your site stays compliant with global privacy regulations.