Claude Code
Run once in your terminal:
claude mcp add --transport http swatchly https://swatchly.xyz/mcpConnect Swatchly's free MCP server, or install it as a skill, and your assistant can convert colors, generate palettes, check WCAG and APCA contrast, name colors and export Tailwind — correctly, instead of guessing. No API key, no account.
One endpoint, any MCP client (Streamable HTTP, no auth):
https://swatchly.xyz/mcpRun once in your terminal:
claude mcp add --transport http swatchly https://swatchly.xyz/mcpAdd to .cursor/mcp.json (project) or ~/.cursor/mcp.json (global):
{
"mcpServers": {
"swatchly": { "url": "https://swatchly.xyz/mcp" }
}
}Add to .vscode/mcp.json:
{
"servers": {
"swatchly": { "type": "http", "url": "https://swatchly.xyz/mcp" }
}
}Add to ~/.codex/config.toml (recent versions; older ones can use the bridge below):
[mcp_servers.swatchly]
url = "https://swatchly.xyz/mcp"Add to ~/.codeium/windsurf/mcp_config.json:
{
"mcpServers": {
"swatchly": { "serverUrl": "https://swatchly.xyz/mcp" }
}
}Bridge the remote server with mcp-remote (or add it as a custom connector where your plan supports it):
{
"mcpServers": {
"swatchly": {
"command": "npx",
"args": ["-y", "mcp-remote", "https://swatchly.xyz/mcp"]
}
}
}curl -s https://swatchly.xyz/mcp \
-H 'content-type: application/json' -H 'accept: application/json, text/event-stream' \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"check_contrast","arguments":{"foreground":"#1b264f","background":"#f4e9cd"}}}'A skill teaches your assistant when and how to use Swatchly. It's a single small file.
Personal skill (all projects), or use .claude/skills for one project:
mkdir -p ~/.claude/skills/swatchly-color && \
curl -fsSL https://swatchly.xyz/ai/skill/SKILL.md -o ~/.claude/skills/swatchly-color/SKILL.md
# or, project-only:
mkdir -p .claude/skills/swatchly-color && \
curl -fsSL https://swatchly.xyz/ai/skill/SKILL.md -o .claude/skills/swatchly-color/SKILL.mdAdds an agent-requested rule:
mkdir -p .cursor/rules && \
curl -fsSL https://swatchly.xyz/ai/skill/swatchly.mdc -o .cursor/rules/swatchly.mdcAppends to your AGENTS.md (read by Codex and most coding agents):
curl -fsSL https://swatchly.xyz/ai/skill/AGENTS.md >> AGENTS.mdView the files: SKILL.md · Cursor rule · AGENTS.md snippet. They only contain instructions and public URLs.
| Tool | What it does |
|---|---|
get_color | Get everything about a color Full details for one color: HEX/RGB/HSL/HSV/HWB/CMYK/Lab/LCh/Luv/OKLab/OKLCH values, nearest color name, hue family, temperature, contrast on white/black, shades, tints, tones, harmonies (complementary, triadic, ...) and color-blindness simulations including dog vision. |
convert_color | Convert a color between formats Convert one color between HEX, RGB, HSL, HSV, HWB, CMYK, XYZ, Lab, LCh, Luv, OKLab and OKLCH. |
generate_palette | Generate a color palette Generate a harmonious palette in the OKLCH color space. |
check_contrast | Check text/background contrast WCAG 2.2 contrast ratio with AA/AAA verdicts for normal and large text and UI components, plus the APCA Lc value (WCAG 3 draft). |
fix_contrast | Fix a failing color pair Lighten or darken one color (keeping its hue) until the pair reaches a target contrast ratio. |
name_color | Name a color The closest human name for a color (from ~5,000 named colors), the match distance and similar names. |
search_color_names | Search color names Find named colors and their HEX codes by a word, e.g. |
export_palette | Export a palette as code Turn a palette into ready-to-paste code in 30+ formats: CSS variables and gradients, SCSS, Less, Tailwind (v3 config or v4 @theme with 50-950 scales), design tokens (W3C DTCG, Tokens Studio, Style Dictionary), SwiftUI, UIKit, Jetpack Compose, Android XML, Flutter, Unity, TypeScript, Python, R, Markdown, JSON, CSV and palette files (GIMP .gpl, JASC .pal, Paint.NET, Lospec .hex). |
tailwind_scale | Tailwind 50-950 scale Build a Tailwind-style 50-950 color scale from one brand color (the color is kept at its natural step), plus copy-ready Tailwind v4 @theme CSS. |
simulate_color_blindness | Simulate color blindness See how colors look to people with protanopia, protanomaly, deuteranopia, deuteranomaly, tritanopia, tritanomaly, achromatopsia, achromatomaly - or to a dog ('dog'). |
random_colors | Random colors Random colors in a chosen style. |
browse_palettes | Browse curated palettes Search Swatchly's ~3,700 curated palettes, filtered by style (pastel, dark, vintage, neon, warm, cool, earthy, muted, monochromatic, gradient...) or color family (red, blue, green...). |
make_gradient | Gradient steps between two colors Evenly spaced colors between two colors, blended in perceptual OKLab, plus a CSS linear-gradient using OKLCH interpolation. |
color_of_the_year | Pantone Color of the Year Pantone Colors of the Year since 2000 with approximate HEX codes and a matching palette for each. |
A free remote Model Context Protocol server that lets AI assistants such as Claude, Cursor, Copilot and Codex call Swatchly's color tools directly: convert colors, generate palettes, check contrast, export Tailwind and more. Connect it with one command or a short config snippet.
No. The MCP server, the skills and the REST API are free and keyless.
The MCP server gives your assistant callable tools. A skill is a short instruction file that tells the assistant when and how to use Swatchly — through the MCP server if it's connected, or the REST API with curl otherwise. Using both works best.
Swatchly doesn't store the colors or arguments you send. Standard Cloudflare request logs apply. All tools are read-only.
There is no key-based limit, but please follow fair use: responses are deterministic and cached at the edge, so cache on your side and avoid tight loops.
Yes. The engine behind the site, the API and the MCP server is the MIT-licensed swatchly-color crate on GitHub.