CSS Gradient Generator

Design linear, radial and conic CSS gradients with draggable colour stops, presets and ready-to-copy CSS.

  • Runs in your browser
  • Free, no sign-up
Type
Colour stops (2)
Presets

Preview and CSS

CSS
background-color: #0f766e;
background-image: linear-gradient(135deg, #0f766e 0%, #5eead4 100%);

The background-color line is a solid fallback for very old browsers and for email clients that ignore gradients. Linear, radial and conic gradients are supported by all current browsers.

Runs entirely in your browser. Nothing you enter is sent to our server.

How to use the css gradient generator

  1. Choose linear, radial or conic.
  2. Set the angle (linear and conic) or the center point and shape (radial).
  3. Edit colour stops: change colours, drag position sliders, add stops (the new colour is blended from its neighbours) or remove them.
  4. Try a preset as a starting point, or toggle Repeating for stripes and rings.
  5. Copy the CSS, which includes a solid fallback colour.

Worked example

Diagonal teal gradient

Two stops, #0f766e at 0% and #5eead4 at 100%, at 135 degrees produce linear-gradient(135deg, #0f766e 0%, #5eead4 100%), running from the top left to the bottom right. Adding a stop places it at 50% with the blended colour between the two.

How it works

The CSS follows the CSS Images Level 3 and 4 syntax: linear-gradient(angle, stops), radial-gradient(shape at x y, stops) and conic-gradient(from angle at x y, stops), with stops sorted by position. New stops use linear RGB interpolation between neighbouring stops, matching how browsers interpolate by default.

Frequently asked questions

Is my data uploaded?

No. This tool runs entirely in your browser. Your input is processed on your device and is not sent to our server or stored.

Do I need vendor prefixes?

No. Unprefixed linear, radial and conic gradients work in all current browsers. The generated CSS includes a solid background-color as a fallback.

Why does my gradient look banded?

Large areas with close colours can show visible steps on 8-bit displays. Adding a middle stop or slightly more colour difference usually helps.

Can I use gradients in email?

Support in email clients is limited, so the solid fallback colour is what many recipients will see. For email, prefer solid colours or an image.

Limitations

  • Stops use hex colours without transparency.
  • Interpolation in other colour spaces (such as in oklch) is not generated.