Sign up for an ArcGIS account to start building applications with MapLibre GL JS:
Create an account to access, manage, and monitor the use of location services.
ArcGIS Location Platform
- For individual developers.
- Build public applications that don't require users to sign in with an ArcGIS account.
- Billing: Use free tiers and pay-as-you-go to use location services and host your data.
- Learn more about the product and billing at ArcGIS Location Platform.
ArcGIS Online
- For developers in an organization.
- Build private applications for your organization that requires users to sign in with an ArcGIS account.
- Build public applications that don't require users to sign in.
- Build low-code/no-code applications with app builders.
- Billing: Pay for credits yearly to use location services and host your data.
- Learn more about the product and billing at ArcGIS Online.
Browse the topics to learn what you can build with MapLibre GL JS.
Maps
Display 2D maps with the basemap styles service.
Data services
Access and display hosted feature layers, vector tiles, and map tiles from data services.
Geocoding
Find addresses and get suggestions with the geocoding service.
Routing
Find routes and directions and perform analyses with the routing service.
Places
Search for places near a location with the places service.
Data enrichment
Get local facts and demographic data with the GeoEnrichment service.
Spatial analysis
Perform feature analysis with the spatial analysis services.
Create developer credentials so you can get an access token.
API key credentials
- Build public applications that don't require users to sign in with an ArcGIS account.
- Access tokens are long-lived.
- Service usage billed to the developer.
- Learn more in API key authentication.
OAuth 2.0 credentials (for user authentication)
- Build private applications for your organization that requires users to sign in with an ArcGIS account.
- Access tokens are short-lived.
- Service usage is billed to the organization of the user signed into the application.
- Learn more in User authentication.
Build your first mapping application with the basemap styles service using MapLibre GL JS.
<script>
const accessToken = "YOUR_ACCESS_TOKEN";
const basemapEnum = "arcgis/navigation"; // Basemap layer style
const map = new maplibregl.Map({
container: "map", // ID of the div element
style: `https://basemapstyles-api.arcgis.com/arcgis/rest/services/styles/v2/styles/${basemapEnum}?token=${accessToken}`,
zoom: 1,
center: [-20, 20] // Starting location [longitude, latitude]
});
</script>