百科.dev
全部条目在线工具AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
M

maplibre-navigation-android

> 编程语言
开源

Maplibre Navigation SDK for Android

195 stars0 点赞0 次浏览
访问官网GitHub

工具介绍

Maplibre Navigation SDK for Android

MapLibre Navigation SDK for Android (and KMP)

The Maplibre Navigation SDK for Android is built on a fork of the Mapbox Navigation SDK v0.19 which is built on top of the Mapbox Directions API and contains the logic needed to get timed navigation instructions.

With this SDK you can implement turn-by-turn navigation in your own Android app while hosting your Map tiles and Directions API.

[!NOTE]
We are currently active working on converting this pure Android library to a Kotlin Multiplatform library.

License

  • 100% Open Source
  • MIT License
  • No Telemetry

Why have we forked

  1. Mapbox decided to put a closed-source component to their navigation SDK and introduced a non-open-source license. Maplibre wants an open-source solution.
  2. Mapbox decided to put telemetry in their SDK. We couldn't turn this off without adjusting the source.
  3. We want to use the SDK without paying Mapbox for each MAU and without Mapbox API keys.

All issues are covered with this SDK.

What have we changed

  • We completely removed the UI part from the SDK so it will only contain the logic for navigation and not the visuals.
  • We upgraded the Mapbox Maps SDK for Android to MapLibre Native for Android version 9.4.0.
  • We upgraded the NavigationRoute with the possibility to add an interceptor to the request.
  • We changed the locationLayerPlugin to the location component
  • We updated the logic around the implementation of the locationEngine so it can be used with the new locationEngine from the Mapbox SDK.
  • We removed the telemetry class from the project. Nothing is being sent to Mapbox or Maplibre.

Getting Started

This library is available on Maven Central. To use it, add the following to your build.gradle:

Gradle

Step 2. Add the dependency

groovy
  // Core KMP library (without UI)
  implementation 'org.maplibre.navigation:navigation-core:5.0.0-pre13'

  // UI library (Android only)
  implementation 'org.maplibre.navigation:navigation-ui-android:5.0.0-pre13'

Location with Google Play Services (optional)

The Android varoant of navigation-core is fully FLOSS, therefore Google's location library com.google.android.gms.* is not used by default.

If you instead want location updates backed by Google Play Services (FusedLocationProviderClient), add the optional add-on module and pass GoogleLocationEngine explicitly when creating navigation:

groovy
  // Optional, Android only — pulls in com.google.android.gms:play-services-location.
  // Do NOT add this to F-Droid / fully FLOSS builds.
  implementation 'org.maplibre.navigation:navigation-location-gms-android:5.0.0-pre13'
kotlin
import org.maplibre.navigation.core.gms.location.engine.GoogleLocationEngine

val navigation = AndroidMapLibreNavigation(
    context = context,
    locationEngine = GoogleLocationEngine(context, Looper.getMainLooper()),
)

Getting Help

  • Have a bug to report? Open an issue. If possible, include the version of MapLibre Services, a full log, and a project that shows the issue.
  • Have a feature request? Open an issue. Tell us what the feature should do and why you want the feature.

Samples

Android

We have added an Android example app to this repo.

The Valhalla example is aready pre-configured. All other examples needs to be configured with your own tile and direction server. This URLs needs to be set in developer-config.xml, which is generated on first Gradle run.

Multiplatform

The new Kotlin Multiplatform library supports Android, iOS, jvm, js and wasmJs as targets. Sample apps are available for Android and iOS respectively.

Contributing

We welcome feedback, translations, and code contributions! Please see CONTRIBUTING.md for details.

Issues· 0 开放

查看全部 Issues在 GitHub 打开

暂无开放 Issues,或尚未同步最近议题。

> 标签

Java

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月18日
分类编程语言
定价开源

> 相关工具

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言