About Maps SDK for JavaScript
Quickstart
- Get your TomTom API key:
-
Sign up or log in at my.tomtom.com.
-
Create an API key following these instructions.
- Install the SDK:
# npm and Yarn install the peer dependencies for younpm install @tomtom-org/maps-sdk
# pnpm does not, unless you ask it toecho "auto-install-peers=true" >> .npmrc && pnpm add @tomtom-org/maps-sdk- Start building:
- Using an AI coding agent? Install the
/tomtom-maps-sdk-jsskill for SDK-specific assistance:
npx skills add tomtom-international/maps-sdk-js --skill tomtom-maps-sdk-js- Follow the Map Quickstart to display your first map.
- Or try the Services Quickstart to call search, geocoding, or routing APIs.
- Or start from a runnable app in the Examples gallery and adapt it.
For more project setup details, see the Project Setup Guide.
AI coding agent skill
The SDK ships a /tomtom-maps-sdk-js skill with SDK-specific knowledge for AI coding agents (Claude Code, Cursor, GitHub Copilot, Windsurf, and many more). Install it with the command above, then see AI coding with the SDK for the topics it covers and how to invoke them.
Overview
Maps SDK for JavaScript is a JavaScript/TypeScript library for building applications using TomTom map display and geolocation APIs.
It leverages the power of MapLibre GL JS and GeoJSON to seamlessly integrate TomTom maps and services with convenient out-of-the-box support, while staying highly customizable and extensible.
Key features
- Interactive Maps: MapLibre-powered library for styled, service-compatible TomTom Maps
- Comprehensive Services: Easy access to TomTom’s location APIs including search, routing, and geocoding
- GeoJSON Support: Built-in compatibility with the widely-used geospatial data format
- TypeScript Ready: Full TypeScript support with comprehensive type definitions
- Modular Architecture: Use only the features you need with tree-shaking support
Where can you run it?
- Web: Display and configure maps, search for places, plan routes, and interact with location data
- Node.js: Server-side geocoding, route calculation, and data enrichment capabilities
- React Native: Leverage TomTom location services from a single codebase
Bundles
The Maps SDK is made up of three bundles:
- Map: MapLibre-powered library for interactive TomTom Maps with modules for places, routes, traffic, and more.
- Services: GeoJSON services for TomTom location APIs: search, routing, geocoding, EV charging availability, and geometry data.
- Core: Shared configuration, types, and utilities used across Map and Services bundles.
Next steps
- Project Setup Guide
- Learn how the SDK works
- API reference — every exported symbol, its signature and its types