CSS Colors
App · Images & Design · 8 actions
Look up the 148 named CSS colors from the CSS Colors API, the free keyless reference to the color names every browser understands. Get a color's hex, rgb() and hsl() forms by name, list a group such as the blues or the grays, list the light or the dark ones so text stays readable, search the names for a word, find the named color nearest to any hex so a brand value gets a name, or pick one at random for a swatch of the day.
Actions
| Action | What it does |
|---|---|
| Check service status | Check whether the CSS Colors API is answering, and how quickly. |
| Find the nearest CSS color | Find the named CSS color closest to any color value: a hex such as #1E90FE, a short hex such as #19F, or channels such as rgb(30, 144, 254). |
| Get a CSS color | Look up one CSS color by name and get its hex, rgb() and hsl() forms and the group and theme the service files it under. |
| Get a random CSS color | Pick one CSS color at random, from the whole table or from one group or theme, for a placeholder, a swatch of the day or a themed post. |
| List CSS colors | List every named CSS color, all 148, with the hex, rgb() and hsl() forms of each and the group and theme the service files it under. |
| List CSS colors by theme | List the colors the service classes as light or as dark. |
| List CSS colors in a group | List the colors in one of the eleven groups the service sorts the table into: aqua, blue, brown, cyan, gray, green, orange, pink, purple, red and yellow. |
| Search CSS colors | Find the CSS colors whose name contains a word, best match first: a name that is the word, then names that start with it, then names that merely contain it, so a search for blue leads with Blue and BlueViolet before AliceBlue. |
Check service status
Check whether the CSS Colors API is answering, and how quickly. This is the one action that reports a problem as a value instead of failing the step, so a workflow can decide what to do about it. Being reachable but not serving colors is reported separately from being down.
Inputs
None.
Outputs
messagetext- What was found, in one sentence.
onlinetrue/false- True when the service answered with a color.
reachabletrue/false- True when the service answered at all, even with an error.
response_time_msnumber- How long it took to answer, in milliseconds; empty if it did not answer.
status_codenumber- The HTTP status it answered with; empty if it did not answer.
Example output
{
"message": "The CSS Colors API is up and answering.",
"online": true,
"reachable": true,
"response_time_ms": 61.8,
"status_code": 200
}Find the nearest CSS color
Find the named CSS color closest to any color value: a hex such as #1E90FE, a short hex such as #19F, or channels such as rgb(30, 144, 254). The service has no lookup by value, so the table is read once and every color measured against the value, weighted the way the eye weights the channels. An exact match is reported as one, names that share the value (Aqua and Cyan, Gray and Gray) come back as aliases, and the next nearest colors are listed with their distances so a step that wants a choice has one.
Inputs
- Color value
colortextRequired - The color to match, as a hex code with or without the #, a three-digit short hex, or rgb() channels.
- Runners-up
candidate_countnumber - How many of the next nearest colors to list beside the answer, from 0 to 10. Defaults to 3.From 0 to 10.
Outputs
aliaseslist- Other CSS names for the nearest color's value, such as Cyan beside Aqua; empty when it has none.
candidate_countnumber- How many runners-up were listed.
candidateslist- The next nearest colors, nearest first, each with its aliases and distance.
distancenumber- How far the nearest color is from the value, by the eye-weighted (redmean) RGB distance: 0 is an exact match, about 765 black against white.
exacttrue/false- True when the value is exactly a named color.
hextext- The value as a hex code, upper case with its #.
nearestobject- The named CSS color closest to the value.
querytext- The color value as it was given.
Example output
{
"aliases": [],
"candidate_count": 3,
"candidates": [
{
"aliases": [],
"blue": 255,
"distance": 103.4,
"green": 191,
"group": "Blue",
"hex": "#00BFFF",
"hsl": "hsl(195, 100%, 50%)",
"hue": 195,
"lightness": 50,
"name": "DeepSkyBlue",
"red": 0,
"rgb": "rgb(0, 191, 255)",
"saturation": 100,
"theme": "light"
},
{
"aliases": [],
"blue": 225,
"distance": 105.5,
"green": 105,
"group": "Blue",
"hex": "#4169E1",
"hsl": "hsl(225, 73%, 57%)",
"hue": 225,
"lightness": 57,
"name": "RoyalBlue",
"red": 65,
"rgb": "rgb(65, 105, 225)",
"saturation": 73,
"theme": "dark"
},
{
"aliases": [],
"blue": 237,
"distance": 109.3,
"green": 149,
"group": "Blue",
"hex": "#6495ED",
"hsl": "hsl(219, 79%, 66%)",
"hue": 219,
"lightness": 66,
"name": "CornflowerBlue",
"red": 100,
"rgb": "rgb(100, 149, 237)",
"saturation": 79,
"theme": "light"
}
],
"distance": 1.7,
"exact": false,
"hex": "#1E90FE",
"nearest": {
"blue": 255,
"green": 144,
"group": "Blue",
"hex": "#1E90FF",
"hsl": "hsl(210, 100%, 56%)",
"hue": 210,
"lightness": 56,
"name": "DodgerBlue",
"red": 30,
"rgb": "rgb(30, 144, 255)",
"saturation": 100,
"theme": "light"
},
"query": "#1e90fe"
}Get a CSS color
Look up one CSS color by name and get its hex, rgb() and hsl() forms and the group and theme the service files it under. Pick a name from the list or type one from an earlier step: case, spaces and hyphens do not matter, so dodger blue finds DodgerBlue. An unknown name is reported as such, with a pointer to the search.
Inputs
- Color name
nametextRequired - The color to look up. Pick one from the list, or type a name from an earlier step in any case, with or without spaces.
Outputs
colorobject- The color.
requested_nametext- The name as it was given, trimmed.
Example output
{
"color": {
"blue": 160,
"green": 158,
"group": "Cyan",
"hex": "#5F9EA0",
"hsl": "hsl(182, 25%, 50%)",
"hue": 182,
"lightness": 50,
"name": "CadetBlue",
"red": 95,
"rgb": "rgb(95, 158, 160)",
"saturation": 25,
"theme": "light"
},
"requested_name": "CadetBlue"
}Get a random CSS color
Pick one CSS color at random, from the whole table or from one group or theme, for a placeholder, a swatch of the day or a themed post. Give a seed to get the same color every time for that seed: seed with the date and a daily post that retries, or that two people run an hour apart, picks the same color, while tomorrow picks a different one.
Inputs
- Group
grouptext - Only pick from this group. Leave empty to pick from every group.One of:
aqua,blue,brown,cyan,gray,green,orange,pink,purple,red,yellow. - Theme
themetext - Only pick a light or only a dark color. Leave empty for either. The theme is the service's own classification of which text reads on the color as a background: black on a light one, white on a dark one.One of:
light,dark. - Seed
seedtext - Any text you like. The same seed always picks the same color, so a date gives a color of the day and a team name gives each team its own. Leave empty for a fresh pick every time.
Outputs
colorobject- The color picked.
grouptext- The group picked from, in lower case; empty for every group.
pool_sizenumber- How many colors the pick was made from.
seedtext- The seed the pick was made with; empty for a fresh pick.
themetext- The theme picked from, light or dark; empty for either.
Example output
{
"color": {
"blue": 107,
"green": 183,
"group": "Yellow",
"hex": "#BDB76B",
"hsl": "hsl(56, 38%, 58%)",
"hue": 56,
"lightness": 58,
"name": "DarkKhaki",
"red": 189,
"rgb": "rgb(189, 183, 107)",
"saturation": 38,
"theme": "light"
},
"group": null,
"pool_size": 148,
"seed": "2026-09-11",
"theme": null
}List CSS colors
List every named CSS color, all 148, with the hex, rgb() and hsl() forms of each and the group and theme the service files it under. Sort by name, by hue to walk the spectrum, or by lightness to run dark to light, and cap the count to take the first few: the ten lightest is a sort by lightness and a limit of ten.
Inputs
- Sort by
sort_bytext - The order the colors come back in. Name is the service's own alphabetical order. Hue walks the spectrum from red through yellow, green, blue and violet, with the grays at the end. Lightness runs dark to light. Defaults to name.One of:
name,hue,lightness. Default:name. - Number of colors
limitnumber - How many colors to return, from 1 to 200, taken from the front of the sorted list. Leave empty for all of them: the whole table is only 148.From 1 to 200.
Outputs
color_countnumber- How many colors this step returned.
colorslist- The colors, in the order asked for.
requested_countnumber- The Number of colors asked for, kept to 1 to 200; empty when every match was asked for.
sort_bytext- The order the colors are in: name, hue or lightness.
totalnumber- How many colors the table holds (148).
Example output
{
"color_count": 3,
"colors": [
{
"blue": 255,
"green": 248,
"group": "Gray",
"hex": "#F0F8FF",
"hsl": "hsl(208, 100%, 97%)",
"hue": 208,
"lightness": 97,
"name": "AliceBlue",
"red": 240,
"rgb": "rgb(240, 248, 255)",
"saturation": 100,
"theme": "light"
},
{
"blue": 215,
"green": 235,
"group": "Gray",
"hex": "#FAEBD7",
"hsl": "hsl(34, 78%, 91%)",
"hue": 34,
"lightness": 91,
"name": "AntiqueWhite",
"red": 250,
"rgb": "rgb(250, 235, 215)",
"saturation": 78,
"theme": "light"
},
{
"blue": 255,
"green": 255,
"group": "Aqua",
"hex": "#00FFFF",
"hsl": "hsl(180, 100%, 50%)",
"hue": 180,
"lightness": 50,
"name": "Aqua",
"red": 0,
"rgb": "rgb(0, 255, 255)",
"saturation": 100,
"theme": "light"
}
],
"requested_count": 3,
"sort_by": "name",
"total": 148
}List CSS colors by theme
List the colors the service classes as light or as dark. The theme is the service's own classification of which text reads on the color as a background: black on a light one, white on a dark one. 53 are dark and 95 light. Sort them and cap the count; the number in the theme is always reported, however many are returned.
Inputs
- Theme
themetextRequired - The theme to list. A theme read off an earlier color works too, in any case.One of:
light,dark. - Sort by
sort_bytext - The order the colors come back in. Name is the service's own alphabetical order. Hue walks the spectrum from red through yellow, green, blue and violet, with the grays at the end. Lightness runs dark to light. Defaults to name.One of:
name,hue,lightness. Default:name. - Number of colors
limitnumber - How many colors to return, from 1 to 200, taken from the front of the sorted list. Leave empty for all of them: the whole table is only 148.From 1 to 200.
Outputs
color_countnumber- How many colors this step returned.
colorslist- The colors, in the order asked for.
requested_countnumber- The Number of colors asked for, kept to 1 to 200; empty when every match was asked for.
sort_bytext- The order the colors are in: name, hue or lightness.
themetext- The theme listed: light or dark.
total_matchesnumber- How many colors have the theme, however many were returned.
Example output
{
"color_count": 2,
"colors": [
{
"blue": 0,
"green": 0,
"group": "Gray",
"hex": "#000000",
"hsl": "hsl(0, 0%, 0%)",
"hue": 0,
"lightness": 0,
"name": "Black",
"red": 0,
"rgb": "rgb(0, 0, 0)",
"saturation": 0,
"theme": "dark"
},
{
"blue": 255,
"green": 0,
"group": "Blue",
"hex": "#0000FF",
"hsl": "hsl(240, 100%, 50%)",
"hue": 240,
"lightness": 50,
"name": "Blue",
"red": 0,
"rgb": "rgb(0, 0, 255)",
"saturation": 100,
"theme": "dark"
}
],
"requested_count": 2,
"sort_by": "name",
"theme": "dark",
"total_matches": 53
}List CSS colors in a group
List the colors in one of the eleven groups the service sorts the table into: aqua, blue, brown, cyan, gray, green, orange, pink, purple, red and yellow. Keep only the light or only the dark ones, sort them, and cap the count. The number in the group that matched is always reported, however many are returned.
Inputs
- Group
grouptextRequired - The group to list. A group name read off an earlier color works too, in any case; gray is read as gray.One of:
aqua,blue,brown,cyan,gray,green,orange,pink,purple,red,yellow. - Theme
themetext - Keep only the light or only the dark colors in the group. Leave empty for both. The theme is the service's own classification of which text reads on the color as a background: black on a light one, white on a dark one.One of:
light,dark. - Sort by
sort_bytext - The order the colors come back in. Name is the service's own alphabetical order. Hue walks the spectrum from red through yellow, green, blue and violet, with the grays at the end. Lightness runs dark to light. Defaults to name.One of:
name,hue,lightness. Default:name. - Number of colors
limitnumber - How many colors to return, from 1 to 200, taken from the front of the sorted list. Leave empty for all of them: the whole table is only 148.From 1 to 200.
Outputs
color_countnumber- How many colors this step returned.
colorslist- The colors, in the order asked for.
grouptext- The group listed, in lower case.
requested_countnumber- The Number of colors asked for, kept to 1 to 200; empty when every match was asked for.
sort_bytext- The order the colors are in: name, hue or lightness.
themetext- The theme kept, light or dark; empty when both were kept.
total_matchesnumber- How many colors in the group matched, however many were returned.
Example output
{
"color_count": 3,
"colors": [
{
"blue": 237,
"green": 149,
"group": "Blue",
"hex": "#6495ED",
"hsl": "hsl(219, 79%, 66%)",
"hue": 219,
"lightness": 66,
"name": "CornflowerBlue",
"red": 100,
"rgb": "rgb(100, 149, 237)",
"saturation": 79,
"theme": "light"
},
{
"blue": 255,
"green": 191,
"group": "Blue",
"hex": "#00BFFF",
"hsl": "hsl(195, 100%, 50%)",
"hue": 195,
"lightness": 50,
"name": "DeepSkyBlue",
"red": 0,
"rgb": "rgb(0, 191, 255)",
"saturation": 100,
"theme": "light"
},
{
"blue": 255,
"green": 144,
"group": "Blue",
"hex": "#1E90FF",
"hsl": "hsl(210, 100%, 56%)",
"hue": 210,
"lightness": 56,
"name": "DodgerBlue",
"red": 30,
"rgb": "rgb(30, 144, 255)",
"saturation": 100,
"theme": "light"
}
],
"group": "blue",
"requested_count": 3,
"sort_by": "name",
"theme": "light",
"total_matches": 8
}Search CSS colors
Find the CSS colors whose name contains a word, best match first: a name that is the word, then names that start with it, then names that merely contain it, so a search for blue leads with Blue and BlueViolet before AliceBlue. Spaces and case are ignored, so sky blue finds SkyBlue. The service has no search of its own, so the table is read once and matched here, and the total number of matches is always reported.
Inputs
- Search for
querytextRequired - The word to look for in the color names, 2 to 60 characters.
- Number of colors
limitnumber - How many colors to return, from 1 to 200, taken from the front of the sorted list. Leave empty for all of them: the whole table is only 148.From 1 to 200.
Outputs
match_countnumber- How many matches this step returned.
matcheslist- The colors whose name contains the word, best match first.
querytext- The word searched for, trimmed.
requested_countnumber- The Number of colors asked for, kept to 1 to 200; empty when every match was asked for.
searched_countnumber- How many color names were searched (148).
total_matchesnumber- How many color names contain the word, however many were returned.
Example output
{
"match_count": 1,
"matches": [
{
"blue": 255,
"green": 144,
"group": "Blue",
"hex": "#1E90FF",
"hsl": "hsl(210, 100%, 56%)",
"hue": 210,
"lightness": 56,
"name": "DodgerBlue",
"red": 30,
"rgb": "rgb(30, 144, 255)",
"saturation": 100,
"theme": "light"
}
],
"query": "dodger",
"requested_count": null,
"searched_count": 148,
"total_matches": 1
}