Skip to content
This site is a preview of the main branch. The published documentation is at maplibre.org.

Overview

MapLibre Compose shows interactive maps in Compose Multiplatform apps on Android, iOS, desktop, and the web. You build the map with composables and Kotlin state, the same way you build the rest of your UI. The maps render with MapLibre, an open-source map engine, and work with any map style and tiles that MapLibre can load.

This composable shows a street map of Portland:

@Composable
fun MyMap() {
val mapState =
rememberMapState(
baseStyle = BaseStyle.Uri("https://tiles.openfreemap.org/styles/liberty"),
initialCameraPosition =
CameraPosition(center = Position(latitude = 45.521, longitude = -122.675), zoom = 13.0),
)
MaplibreMap(state = mapState)
}
PlatformMap engineStability
AndroidMapLibre NativeBeta
iOSMapLibre NativeBeta
Native macOS (arm64)MapLibre NativeExperimental
Desktop (JVM)MapLibre NativeAlpha
Web (Kotlin/JS)MapLibre GL JSAlpha

MapLibre Native and MapLibre GL JS read the same style format, and you use the same Kotlin API on every platform. Offline downloads are not available in the browser.

Desktop and web are Alpha because they depend on internal details of Compose and Skia. Platform setup lists the requirements of each platform.

The API is not stable yet. Until version 1.0, a minor release can contain breaking changes.