How to make a map with pins using Leaflet

This example shows how to make a map with pins using Leaflet JS. Load a geoJSON of points in Leaflet JS and add your custom pins or icons.


Replace YOUR_MAPTILER_API_KEY_HERE with your own API key. Make sure to protect the key before you publish it!

Learn more

Check out the Leaflet marker with a custom icon to learn How to customize Leaflet icons.