Gradient Color Steps

Generates a smooth run of colours between two or more stops and gives you every intermediate value. Useful for chart scales, heat maps, data visualisation ramps and generating a tint series from a brand colour.

Live demo · real result from this tool
Extra colours between start and end, separated by commas or spaces.

Press Generate to create a result.

Processed on your device — nothing is uploaded.

How to use Gradient Color Steps

  1. Set the start and end colours, and any intermediate stops.
  2. Choose how many steps you want.
  3. Copy the hex values, or the CSS gradient if you want it as a background.
  4. Blending complementary colours in sRGB passes through grey — add a midpoint stop you choose.
  5. For data visualisation, prefer a ramp whose lightness increases steadily rather than a rainbow.
  6. Check any step used behind text against a contrast ratio; a smooth ramp crosses the readable threshold somewhere in the middle.

Why the middle of a blend goes muddy

Interpolating in sRGB means averaging the red, green and blue channels, and that path frequently passes through grey. Blue to yellow is the notorious example: the midpoint of the two channel sets is a desaturated sludge, because the route between them in RGB space goes near the centre where all colours are grey. Perceptual spaces such as OKLCH and Lab take a path that keeps saturation, which is why modern design tools and CSS’s newer interpolation keywords produce visibly better blends between distant hues.

Colour ramps for data are a different problem

A gradient that looks attractive can badly misrepresent data. The classic rainbow scale is the worst offender: it has sharp perceptual boundaries at yellow and cyan that invent structure in the data, and it becomes unreadable in greyscale and for colour-blind readers. Sequential data wants a ramp that increases monotonically in lightness — viridis, magma, or a simple single-hue light-to-dark. Diverging data with a meaningful midpoint wants two hues meeting at a neutral. Categorical data wants distinct hues, not a gradient at all.

Generating a tint scale from one brand colour

A practical use: blend your accent toward white for the light steps and toward a very dark neutral for the dark ones, taking evenly spaced samples to get a 50–900 scale like the ones design systems ship. Blending toward pure white and pure black gives washed-out and muddy ends; blending toward a very light tinted white and a near-black that carries a little of the hue keeps the scale coherent.

Frequently asked questions

What does this tool generate?
A set of discrete colors interpolated evenly between a start and end color — like sampling a gradient at fixed points.
How many steps can I create?
Choose any number of steps; more steps give a smoother transition between the two endpoint colors.
Where are stepped gradients useful?
In charts, heatmaps and categorical scales where you need a fixed number of distinct but related colors.
Why does my gradient look grey in the middle?
Because sRGB interpolation takes a path near the centre of the colour space between distant hues. Add a midpoint stop in a saturated colour you choose, or interpolate in a perceptual space such as OKLCH where support allows.
What is the best colour scale for a heat map?
A perceptually uniform sequential scale such as viridis or magma, where lightness increases steadily. These stay readable in greyscale and for colour-blind viewers, and they do not create false boundaries the way a rainbow scale does.
How do I make a tint scale from my brand colour?
Blend it toward a very light tinted white for the light end and a near-black carrying a trace of the hue for the dark end, then take evenly spaced samples. Blending to pure white and pure black gives ends that look washed out and muddy.

Written by the ToolsRift team · Last updated

Pages are drafted with AI assistance and checked by automated tests. How we write and check pages.

Was this tool useful?

Report a problem

Start typing to search every tool.

↑ ↓ to moveEnter to openEsc to close