MCP server for Ultralytics Platform projects, datasets, training, prediction, exports, and models.
MCP server for Ultralytics Platform workflows: projects, datasets, models, training, prediction, exports, and dataset uploads.
[!IMPORTANT] Independent community project. Not affiliated with or endorsed by Ultralytics.
Install · Tools · Safety · Troubleshooting
traffic-cams and upload ./clips/junction.mp4 as a dataset."yolo11n on traffic-cams for 50 epochs."https://example.com/frame.jpg, then download the weights to ./weights."scratch project to trash." (restorable for 30 days)https://github.com/user-attachments/assets/449d051b-d162-4539-93c5-94be478303f0
You need:
>=20ffmpeg and ffprobe on PATH, to upload a dataset from a local video fileSign in at Ultralytics Platform, open
Settings -> API Keys, and create or copy a key. The official
API key docs cover
creation, usage, and revocation.
| Variable | Required | Description |
|---|---|---|
ULTRALYTICS_API_KEY | ✅ | Ultralytics API key. Expected format: ul_ followed by 40 hex characters |
ULTRALYTICS_API_BASE | ❌ | Advanced: override API base URL. Default: https://platform.ultralytics.com/api |
Treat ULTRALYTICS_API_KEY as a bearer token. Pass it through your MCP client's
environment configuration only. Never paste real keys into prompts, scripts, or
committed config files. Project-scoped .mcp.json files are ignored by this repo
to reduce accidental key commits; if a key is exposed, revoke it in Ultralytics
Platform and create a replacement.
Works in MCP clients that accept JSON stdio server definitions.
{
"mcpServers": {
"ultralytics": {
"command": "npx",
"args": ["-y", "ultralytics-mcp@latest"],
"env": {
"ULTRALYTICS_API_KEY": "ul_your_api_key_here"
}
}
}
}
These examples track the latest published npm release. Restart your MCP client or session after upgrading, so the new server process picks up the latest package.
Add the standard config above through Antigravity settings, or by editing your configuration file directly.
claude mcp add ultralytics --env ULTRALYTICS_API_KEY=ul_your_api_key_here -- npx -y ultralytics-mcp@latest
Or add a project-scoped server in repo-root .mcp.json:
{
"mcpServers": {
"ultralytics": {
"command": "npx",
"args": ["-y", "ultralytics-mcp@latest"],
"env": {
"ULTRALYTICS_API_KEY": "ul_your_api_key_here"
}
}
}
}
Follow the MCP install guide with the standard config above.
codex mcp add ultralytics --env ULTRALYTICS_API_KEY=ul_your_api_key_here -- npx -y ultralytics-mcp@latest
Or add it directly to ~/.codex/config.toml:
[mcp_servers.ultralytics]
command = "npx"
args = ["-y", "ultralytics-mcp@latest"]
[mcp_servers.ultralytics.env]
ULTRALYTICS_API_KEY = "ul_your_api_key_here"
Important The install button writes a placeholder key. After installing, open your Cursor MCP config and replace
ul_your_api_key_herewith your Ultralytics API key, then restart Cursor.
To install manually, go to Cursor Settings -> MCP -> Add new MCP Server
(or edit ~/.cursor/mcp.json) and use the standard config above.
Follow the MCP install guide with the standard config above.
Important The install button writes a placeholder key. After installing, open your VS Code MCP config and replace
ul_your_api_key_herewith your Ultralytics API key, then restart VS Code.
To install manually, follow the MCP install guide, or use the VS Code CLI:
code --add-mcp '{"name":"ultralytics","command":"npx","args":["-y","ultralytics-mcp@latest"],"env":{"ULTRALYTICS_API_KEY":"ul_your_api_key_here"}}'
Run claude mcp list or codex mcp list. You should see ultralytics among
the configured MCP servers.
See TOOLS.md for the full parameter reference, safety notes, local-path behavior, and examples for the tricky tools.
export_create requires confirm_cost: truetraining_start requires confirm_cost: true, plus confirm_history_loss: true when restarting training on an existing model that already has a recorded run. That path replaces its status, epoch count, and training result history irrecoverablytraining_start in checkpoint mode (a base checkpoint like yolo11n.pt, not an existing model ref) creates the project model before the platform checks the checkpoint's task against the dataset'smodels_delete if it is unwantedexport_cancel proceeds only when it observes an export as queued, starting, or running, and refuses every other status, including unrecognized ones. Because the status check and the cancel request are not atomic, an export that finishes between them may have its artifact irreversibly deletedAuthorizationmodel_predict with file_path, and deployment_predict read files from the MCP client host; approve calls only for paths you expect to share with Ultralyticsmodel_download writes to the requested local path; review output_path and overwrite before approvingdata.yaml class names) to an existing dataset imports its labels and merges classesULTRALYTICS_API_KEY must start with ul_ and contain exactly 40 hex
characters after the prefix.
Run claude mcp list or codex mcp list, then verify that npx and Node.js
are installed and that ULTRALYTICS_API_KEY reached the client — passed with
--env when adding the server, or set in ~/.codex/config.toml. In Claude
Code, claude mcp get ultralytics shows the resolved config.
To smoke-test the server on its own:
ULTRALYTICS_API_KEY=ul_your_api_key_here npx -y ultralytics-mcp@latest
If the command exits immediately with a config error, fix the environment first.
For authentication, rate-limit, or endpoint behavior, compare against the official Ultralytics Platform REST API docs. When asking for help, include the tool name, request summary, response status, redacted response body, and a minimal reproduction. Do not include real API keys, signed URLs, private dataset contents, or private model artifacts.
See CONTRIBUTING.md for setup, the check suite, and the live smoke test.
Source-derived launch command. Check the maintainer’s required arguments and credentials before running:
npx -y ultralytics-mcpMerge this template into ~/Library/Application Support/Claude/claude_desktop_config.json. Keep existing servers. Add any arguments, credentials, and permissions required by the maintainer; this template has not been install-tested.
{
"mcpServers": {
"io-github-amanharshx-ultralytics-mcp": {
"command": "npx",
"args": [
"-y",
"ultralytics-mcp"
]
}
}
}Restart Claude Desktop completely for changes to take effect. Confirm the server appears connected in the client’s tool list, then try a read-only example from its documentation.
Claude Desktop setup referenceultralytics-mcpnpmUltralytics Platform MCP works with any MCP-compatible client. Copy the config snippet from the Configuration section above and add it to the file shown for your client, then restart the application.
~/Library/Application Support/Claude/claude_desktop_config.jsonRestart Claude Desktop completely for changes to take effect.~/.cursor/mcp.jsonRestart Cursor for changes to take effect..vscode/mcp.jsonReload VS Code window for changes to take effect.~/.codeium/windsurf/mcp_config.jsonRestart Windsurf for changes to take effect..mcp.jsonSave at the project root, then start Claude Code in that project and review the MCP server approval prompt. Keep real credentials out of shared files.