maplibre_gl 0.27.0 copy "maplibre_gl: ^0.27.0" to clipboard
maplibre_gl: ^0.27.0 copied to clipboard

Native MapLibre maps for Flutter: Mapbox Vector Tile (MVT) and PMTiles sources, custom styles, GeoJSON layers and offline regions on Android, iOS and Web.

MapLibre Logo

Flutter MapLibre GL

Interactive, fully styleable vector maps on Android, iOS and Web, powered by open source MapLibre.
Vendor-neutral: host your own tiles or mix providers, no account or API key required to get started.

Pub Version Likes Pub Points Stars Melos

✨ Try it before you install: run the package live in your browser and read the full docs, no setup and no API keys.

Live demo    Documentation

πŸ–ΌοΈ What it looks like #

3D buildings Clustering Globe, on web
Midtown Manhattan with the camera pitched and rotated GeoJSON points clustered with live counts globe projection rendered by MapLibre GL JS
Data-driven styling Heatmaps Annotations
countries coloured and faded by their own properties point density drawn on the GPU symbol markers with custom icons and labels

All of these are live in the demo, and every guide embeds an interactive map you can pan and click.

πŸš€ Quick start #

flutter pub add maplibre_gl
import 'package:maplibre_gl/maplibre_gl.dart';

// Anywhere with bounded constraints, a Scaffold body for example:
MapLibreMap(
  initialCameraPosition: const CameraPosition(target: LatLng(0, 0), zoom: 2),
  styleString: 'https://demotiles.maplibre.org/style.json',
  onStyleLoadedCallback: () {
    // Add sources, layers and images here.
  },
);

Requires Flutter 3.29+ Β· Dart 3.7+ Β· Android 5.0 (API 21)+ Β· iOS 13+ Β· a browser with WebGL2 (Safari 15+).

Then head to the getting started guide for platform setup (location permissions on iOS/Android; web needs no index.html changes) and to learn how to add markers, layers, offline tiles and more.

Upgrading from an earlier release? See the migration guide.

πŸ—ΊοΈ Feature support #

Engines: maplibre-native (Android/iOS), maplibre-gl-js (Web). Only a subset of native SDK APIs is exposed, PRs to extend coverage are welcome.

Feature Android iOS Web
Style, Camera, Gesture βœ… βœ… βœ…
User Location βœ… βœ… βœ…
Annotations βœ… βœ… βœ…
All layer types (Symbol to Hillshade) βœ… βœ… βœ…
GeoJSON, vector, raster & PMTiles sources βœ… βœ… βœ…
Offline regions βœ… βœ… ❌
Feature state βœ… ❌ βœ…

See the full feature matrix for details.

Not supported: desktop targets (Windows, macOS, Linux), and Flutter widgets inside the map. The map is a platform view rendered by the native engines, so your widgets go over it in a Stack, not between its layers.

Example app Β· API reference Β· Changelog Β· Discussions Β· Issues Β· Slack (#maplibre-flutter)

🀝 Contributing #

dart pub global activate melos
melos bootstrap

This is a melos workspace (maplibre_gl, maplibre_gl_web, maplibre_gl_platform_interface and the example app). Layer/source helpers are generated, don't edit them directly; run melos run generate && melos run format-all. See CONTRIBUTING.md before opening a PR, and the architecture docs for an overview.

This project is a fork of flutter-mapbox-gl. ❀️

πŸ’ Contributors #

A huge thanks to everyone who has contributed to this project!

Contributors

Made with contrib.rocks.

πŸ“„ License #

See LICENSE.

126
likes
160
points
94.8k
downloads
screenshot

Documentation

Documentation
API reference

Publisher

verified publishermaplibre.org

Weekly Downloads

Native MapLibre maps for Flutter: Mapbox Vector Tile (MVT) and PMTiles sources, custom styles, GeoJSON layers and offline regions on Android, iOS and Web.

Repository (GitHub)
View/report issues
Contributing

Topics

#map #maplibre #vector-tiles #openstreetmap #gis

Funding

Consider supporting this project:

github.com
opencollective.com

License

BSD-3-Clause (license)

Dependencies

collection, flutter, maplibre_gl_platform_interface, maplibre_gl_web

More

Packages that depend on maplibre_gl

Packages that implement maplibre_gl