Free, customisable map components for React, built on MapLibre GL and styled like shadcn/ui
open sourceMITfree
mapcn is a set of free, open source map components for React, built on MapLibre GL, styled with Tailwind and following shadcn/ui's patterns, added to a project with one command. The components are theme-aware (light and dark), composable and give full access to MapLibre underneath: markers with popups, tooltips and labels, routes and paths, and zoom, compass, locate and fullscreen controls. It also publishes an agent skill that teaches coding agents to use it. Its default styles use CARTO basemaps from OpenStreetMap data, and it works with any MapLibre-compatible basemap provider.
Problems it solves
- add an interactive map to my shadcn/ui React app that matches its styling
- free map components for React without a Mapbox token
- show markers with popups and a route on a map in a Next.js app
Features
- React map components on MapLibre GL, styled with Tailwind
- follows shadcn/ui's patterns and adapts to light and dark mode
- markers with popups, tooltips and labels
- routes, paths and map controls
- an agent skill for coding agents
Limitations
Alternatives
The same job
These do what mapcn does.
- Leaflet The leading open-source JavaScript library for interactive maps
- MapLibre GL JS Open-source TypeScript library for interactive vector tile maps in the browser
- OpenLayers High-performance JavaScript library for interactive web maps