Mapbox GL open-source fork

Published Jan 08, 2021

After Mapbox announced the closure of Mapbox GL JS, their JavaScript library for displaying maps using WebGL, the community made a collective decision to maintain and further develop the last open-source version and build a free alternative. Read the story and technical details.

MapLibre is born

In December 2020, Mapbox released the second version of their JavaScript library for publishing maps online. However, this time all the new features were overshadowed by a change in the license: previously free as a freedom, it became closed for external contributors and usage was restricted to people with active Mapbox subscriptions. One have to pay even for loading this JavaScript library.

The community reacted swiftly: forks of the latest open-source version were made almost immediately by multiple parties. In another positive development, the community came together the next day and agreed to make this a joint effort, rather than splitting energies. A video call was organized and the MapLibre coalition was formed. It includes people working for MapTiler, Elastic, StadiaMaps, Microsoft, Ceres Imaging, WhereGroup, Jawg, Stamen Design, etc.

The name, MapLibre, stands as an abbreviation for Map library restarted (or reinvented), at the same moment the word Libre refers to freedom & independence.

Members of open-source communities and companies working in the map industry agreed on basic rules, which were formalized into a guiding Memorandum. This summarized the project goals, rough roadmap, community governance details, and communication channels. Read the full text of the memorandum and join the effort: new members are welcomed!

Independent JavaScript GL mapping library

MapLibre is based on Mapbox GL JS 1.13, the most recent version available under the BSD license. The source code and ticketing system is hosted on GitHub. Together with the fork, the whole ecosystem around the library (NPM packages, binding to react, …) were also updated.

For a complete working example of the map with a style loaded from a CDN (JavaScript and HTML code sample), click on the button below (note, MapLibre is still under heavy development - this is the fourth release candidate). However, MapLibre will always be provider-independent, and you can load maps from your preferred provider or self-hosted maps.

JavaScript tutorial

Current Mapbox GL JS users can simply switch by changing a few lines of code.

If you use npm and depend on mapbox-gl directly, simply replace mapbox-gl with maplibre-gl in package.json:

You can use this library in your React app as well with help of React.useRef and React.useEffect hooks. See our live example. The most popular bindings for React and other libraries are going to be updated soon.

Native SDK for Android & iOS

As development of open-source mobile map SDKs for Android & iOS was discontinued somewhere in the middle of last year, the MapTiler team was for some time working internally on own version. This latest situation sped things up, and we are releasing the code for a broad community.

MapLibre GL Native was forked from mapbox-gl-native prior to their switch to a non-OSS license. The fork also includes Maps SDK for iOS and macOS (forked from mapbox-gl-native-ios) and Android SDK (forked from mapbox-gl-native-android). The first version is available on GitHub.

The source code which was updated to the latest version of Clang/Xcode and can be used immediately. Continuous integration and delivery was moved over to GitHub Actions from CircleCI and iOS binaries are distributed as a Swift package that contains binaries packaged using the new XCFramework format.

Android tutorial     iOS tutorial

Our further proposal is to move this fork under the wings of MapLibre and further develop it together with the community. Suggestions for improvements and pull requests are welcomed!

Even though Mapbox has changed the direction in relation to open-source, we would like to express a huge appreciation to the great team of Mapbox engineers for all their effort made on the development of the numerous tools and components used in here.

Petr Pridal

Founder & CEO
Published on Jan 08, 2021

© 2020 MapTiler. All rights reserved. Privacy & Terms.
Follow us on