Color Converter API
Convert colors between HEX, RGB, HSL and CMYK, get complementary, analogous, triadic palettes, shades and tints, the best text color and WCAG contrast ratio.
Authentication & base URL
Subscribe through one of our marketplace listings; your marketplace API key and base URL are shown there. All endpoints return JSON over HTTPS, served from a global edge network (typically 20–150 ms).
Endpoints
GET /v1/color
Color info
| Parameter | In | Description | Example |
|---|---|---|---|
color * | query | hex, rgb() or hsl() | ff8800 |
compare | query | Second color for contrast | ffffff |
Example
GET /v1/color?color=ff8800&compare=ffffff
{
"hex": "#ff8800",
"rgb": {
"r": 255,
"g": 136,
"b": 0
},
"hsl": {
"h": 32,
"s": 100,
"l": 50
},
"cmyk": {
"c": 0,
"m": 47,
"y": 100,
"k": 0
},
"luminance": 0.3887,
"bestTextColor": "#000000",
"palettes": {
"complementary": [
"#0077ff"
],
"analogous": [
"#ff0800",
"#f6ff00"
],
"triadic": [
"#00ff88",
"#8800ff"
],
"shades": [
"#cc6d00",
"#995200",
"#663600",
"#331b00"
],
"tints": [
"#ffa033",
"#ffb866",
"#ffcf99",
"#ffe7cc"
]
},
"contrast": {
"with": "#ffffff",
"ratio": 2.39,
"AA": false,
"AALarge": false,
"AAA": false
}
}Convert colors between HEX, RGB, HSL and CMYK, get complementary, analogous, triadic palettes, shades and tints, the best text color and WCAG contrast ratio.
Use cases
Design tools, theme generators, accessibility checks (WCAG AA/AAA), branding apps, print preparation (CMYK).
Why this API
- Fast: runs on a global edge network, typical response well under 1 second.
- Reliable: simple JSON, clear error messages.
- Fair pricing: Free plan 500 requests/month, Pro 25,000 for $4.99, Ultra 150,000 for $14.99.
Pricing
Free plan with 500 calls per month, then Pro (25,000 calls for $4.99/month) and Ultra (150,000 calls for $14.99/month). See all plans.