19 skills published from this repository. No description was given upstream, so this issue takes its voice from the chapters themselves.
19 chapters · 1 hour 2 minutes · 13,849 words
19 chapters · 62 min
npx skills add mapbox/mapbox-agent-skills/plugin marketplace add mapbox/mapbox-agent-skillsComprehensive Agent Skills that teach AI assistants how to build fast, beautiful, secure Mapbox applications across Web, iOS, and Android platforms. Covers performance optimization, cartographic design, framework integration, platform migration, search integration, geospatial operations, and security best practices.
This repository includes a Codex plugin manifest at plugins/mapbox/.codex-plugin/plugin.json and a repo marketplace at .agents/plugins/marketplace.json.
Codex marketplaces currently expect a plugin subdirectory such as plugins/mapbox. To avoid maintaining a second tracked copy of every skill, keep editing the root skills/ directory and generate the local plugin package before testing:
main, last pushed 7 August 2026.SKILL.md, not by matching a directory convention. One layout observed: skills/*/SKILL.md.h1 and no skipped levels:.claude-plugin/marketplace.json by Mapbox Plugin Marketplace, declaring 1 plugin. It is read for editorial metadata only — never as the skill index, which is always the repository tree./mapbox/mapbox-agent-skills.md, and each chapter at its own .md URL.npm run build:codex-plugin
codex plugin marketplace add .
codex plugin marketplace listThen restart Codex and install the mapbox plugin from the Mapbox Agent Skills marketplace.
The generated plugins/mapbox/skills/ and plugins/mapbox/.mcp.json files are ignored by git.
This repository conforms to the Open Plugins specification (opens in a new tab), making it installable in any conformant tool - Cursor, Codex, GitHub Copilot, Claude Code, and more.
Add the marketplace source:
/plugin marketplace add mapbox/mapbox-agent-skillsThen install the plugin:
/plugin install mapboxInstall as a Claude Code plugin to get skills and MCP servers in one step:
/plugin marketplace add mapbox/mapbox-agent-skillsThen install the plugin:
/plugin install mapboxThis adds all Mapbox skills and connects the mapbox, mapbox-devkit, and mapbox-docs MCP servers automatically.
Install all Mapbox Agent Skills:
npx skills add mapbox/mapbox-agent-skillsInstall specific skills:
npx skills add mapbox/mapbox-agent-skills --skill mapbox-web-performance-patternsList available skills:
npx skills add mapbox/mapbox-agent-skills --list💡 Pro tip: These skills work great on their own, but they’re even more powerful when combined with the Mapbox MCP DevKit Server (opens in a new tab). Skills provide the expertise (performance patterns, design principles), while MCP tools provide the actions (create styles, generate previews). Together, they enable complete workflows from design to deployment.
Agent Skills are folders containing instructions and resources that AI assistants (like Claude Code, Cursor, GitHub Copilot) can discover and use to perform tasks more effectively. Unlike tools (which provide actions) or prompts (which provide workflows), skills provide domain expertise - the “know-how” that helps AI make informed decisions.
Think of skills as giving your AI assistant a specialized education in Mapbox development best practices.
Platform Coverage:
Expert guidance on choosing between offline geometric tools and routing APIs for geospatial operations.
Helps AI assistants select the right tool based on problem type (geometric vs routing), accuracy requirements, and performance needs. Features the “as the crow flies” vs “as the crow drives” decision framework.
Use when:
Key topics:
Tool categories covered:
Complete workflow for implementing Mapbox search in applications from discovery to production.
Guides AI assistants through the entire search integration process: asking discovery questions, selecting the right product, implementing with best practices, and avoiding common pitfalls. Embodies collective knowledge from the Mapbox search team and customer learnings.
Use when:
Key workflow:
Covers all platforms:
Best practices from “the good parts”:
Expert guidance on choosing the right search tool and parameters for geocoding, POI search, and location discovery.
Helps AI assistants select between search_and_geocode, category_search, and reverse_geocode tools, and optimize parameters like proximity, bbox, country, limit, and more.
Use when:
Key topics:
Search tools covered:
Migration guide between Mapbox GL JS and MapLibre GL JS in both directions.
Covers the fork history, API compatibility (~95% identical), token handling, style differences, and feature parity. Helps developers migrate in either direction or use both libraries together.
Use when:
Key topics:
Covers:
Performance optimization patterns for building fast, efficient Mapbox GL JS web applications.
Covers initialization waterfalls, bundle size, rendering performance, memory management, and web optimization. Patterns are prioritized by impact on user experience (Critical → High Impact → Optimization).
Use when:
Key topics:
Based on: Performance principles from Vercel’s react-best-practices (opens in a new tab) and Mapbox GL JS patterns
Expert guidance on map design principles, color theory, visual hierarchy, typography, and cartographic best practices.
Use when:
Key topics:
Official integration patterns for Mapbox GL JS across popular web frameworks and Web Components.
Covers React, Vue, Svelte, Angular, Next.js, and framework-agnostic Web Components (Custom Elements) with proper lifecycle management, token handling, and search integration. Based on Mapbox’s create-web-app scaffolding tool.
Use when:
Key topics:
Integration patterns for Mapbox Maps SDK on iOS with Swift, SwiftUI, UIKit, and mobile optimization.
Covers Swift/SwiftUI integration, lifecycle management, token handling, offline maps, Navigation SDK, and battery/memory optimization for iOS devices.
Use when:
Key topics:
Integration patterns for Mapbox Maps SDK on Android with Kotlin, Jetpack Compose, and mobile optimization.
Covers Kotlin/Jetpack Compose integration, lifecycle management, token handling, offline maps, Navigation SDK, and battery/memory optimization for Android devices.
Use when:
Key topics:
Common style patterns, layer configurations, and recipes for typical mapping scenarios.
Use when:
Key topics:
Expert guidance on validating, optimizing, and ensuring quality of Mapbox styles.
Covers validation, accessibility checks, and optimization techniques for production-ready styles.
Use when:
Key topics:
Security best practices for Mapbox access tokens.
Covers scope management, URL restrictions, rotation strategies, and incident response.
Use when:
Key topics:
Common patterns for building store locators, restaurant finders, and location-based search applications.
Comprehensive guide covering marker display strategies, filtering, distance calculation, interactive lists synced with maps, and directions integration. Perfect for building any location-based finder application.
Use when:
Key topics:
Covers all marker strategies:
mapboxgl.Marker()Common use cases:
Complete implementation:
Comprehensive migration guide for developers moving from Google Maps Platform to Mapbox GL JS.
Covers API equivalents, coordinate order gotchas, pattern translations, and step-by-step migration strategies with side-by-side code examples.
Use when:
Key topics:
Covers all major features:
Patterns for visualizing data on Mapbox maps.
Covers choropleth maps, heat maps, clustering, bubble charts, 3D extrusions, and animated data layers. Includes data-driven styling with style expressions, color scales, and performance optimization.
Use when:
Key topics:
fill, heatmap, circle, fill-extrusion, line)Integration patterns for Mapbox MCP DevKit Server in AI coding assistants.
Setup and usage guide for the Mapbox MCP DevKit Server (opens in a new tab) — an MCP server for AI coding workflows. Covers style management, token creation, data validation, and documentation access through Claude Code, Cursor, and other AI assistants.
Use when:
Key topics:
Integration patterns for Mapbox MCP Server in AI applications and agent frameworks.
Patterns for integrating the Mapbox MCP Server (opens in a new tab) into production AI applications. Covers all major Python and TypeScript agent frameworks with working examples and correct API usage.
Use when:
Key topics:
{longitude, latitude} objects)Skills in this repository are automatically discovered by Claude Code when placed in:
# Install all skills
npx skills add mapbox/mapbox-agent-skills
# Or manually symlink (for development)
mkdir -p .claude
ln -s ~/git/mapbox-agent-skills/skills .claude/skillsSkills are automatically activated when relevant to your task.
npx skills add mapbox/mapbox-agent-skills -a cursornpx skills add mapbox/mapbox-agent-skills -a vscodeThe skills CLI supports: OpenCode, Codex, Antigravity, and more. Run npx skills add --help for full list.
If your AI assistant doesn’t support the skills CLI, you can copy skill files directly:
# For Claude Code — copy SKILL.md into .claude/skills/
mkdir -p .claude/skills/mapbox-web-performance-patterns
curl -o .claude/skills/mapbox-web-performance-patterns/SKILL.md \
https://raw.githubusercontent.com/mapbox/mapbox-agent-skills/main/skills/mapbox-web-performance-patterns/SKILL.md
# For Codex, Copilot, and other AGENTS.md-based tools — copy to project root
curl -O https://raw.githubusercontent.com/mapbox/mapbox-agent-skills/main/skills/mapbox-web-performance-patterns/AGENTS.mdOnce installed, skills activate automatically when relevant:
👤 User: “My Mapbox map with 5,000 restaurant markers is slow. How do I optimize it?”
🤖 Claude: [Uses mapbox-web-performance-patterns skill]
“Based on the marker performance thresholds:
10,000: Server-side clustering
For 5,000 markers, you need clustering. Here’s the pattern…”
👤 User: “Set up Mapbox in my React app”
🤖 Claude: [Uses mapbox-web-integration-patterns skill]
“I’ll use the React pattern with useRef + useEffect:
import { useRef, useEffect } from 'react';
import mapboxgl from 'mapbox-gl';
import 'mapbox-gl/dist/mapbox-gl.css';
function MapComponent() {
const mapRef = useRef(null);
const mapContainerRef = useRef(null);
useEffect(() => {
mapboxgl.accessToken = import.meta.env.VITE_MAPBOX_ACCESS_TOKEN;
mapRef.current = new mapboxgl.Map({
container: mapContainerRef.current,
center: [-71.05953, 42.3629],
zoom: 13
});
// CRITICAL: Cleanup to prevent memory leaks
return () => {
mapRef.current.remove();
};
}, []);
return <div ref={mapContainerRef} style={{ height: '100vh' }} />;
}Key points:
👤 User: “Create a map style for a restaurant finder app”
🤖 Claude: [Uses mapbox-cartography + mapbox-style-patterns skills]
“For a restaurant finder, you need:
Design (from cartography skill):
Style pattern (from style-patterns skill): I’ll apply the POI Finder pattern:
These Agent Skills work together with the Mapbox MCP DevKit Server (opens in a new tab):
| Component | Purpose | Example |
|---|---|---|
| Agent Skills (this repo) | Provide expertise | Performance patterns, design principles |
| MCP Tools | Execute actions | create_style_tool, list_tokens_tool |
| MCP Prompts | Orchestrate workflows | create-and-preview-style workflow |
Example workflow:
User: "Create a high-performance map for my restaurant finder"
1. [mapbox-cartography skill] → Understands restaurant maps need high contrast, muted background
2. [mapbox-token-security skill] → Creates token with only styles:read scope, URL restrictions
3. [mapbox-style-patterns skill] → Applies POI Finder pattern
4. [MCP style_builder_tool] → Generates style JSON
5. [MCP create_style_tool] → Creates style in Mapbox account
6. [mapbox-web-performance-patterns skill] → Recommends clustering for > 1,000 markers
7. [MCP preview_style_tool] → Generates preview linkWant to see these skills in action? Check out the examples/ (opens in a new tab) directory for both conversation transcripts and working code examples.
Realistic conversation transcripts showing how AI assistants use the skills:
Complete, runnable applications following skill patterns:
Web:
iOS:
Android:
Each example includes:
Each skill follows this structure:
skill-name/
├── SKILL.md # Main skill file (required)
│ ├── YAML frontmatter # name, description
│ └── Markdown content # Instructions and guidance
└── [optional files] # Additional resourcesskills/SKILL.md with YAML frontmatter and instructionsGuidelines:
To test skills locally:
# Clone repo
git clone https://github.com/mapbox/mapbox-agent-skills.git
cd mapbox-agent-skills
# Install in Claude Code
npx skills add . -a claude-code
# Or symlink for development
mkdir -p .claude
ln -s $(pwd)/skills .claude/skillsTest with prompts like:
Web:
iOS:
Android:
Mapbox Documentation:
Related Tools:
We welcome contributions of new skills or improvements to existing ones! Please see our Contributing Guide (opens in a new tab) for detailed instructions on creating skills, testing, and submitting pull requests.
For questions or suggestions, please open an issue (opens in a new tab).
MIT License - see LICENSE (opens in a new tab) file for details.
Related Projects: