CSS Gradient Generator
background: linear-gradient( 135deg, #6366f1 0%, #a855f7 50%, #ec4899 100% );
Gradient · Linear · 3
Cmd/Ctrl+Shift+R random · Esc exit
Overview
Design CSS gradients visually in your browser
Build linear, radial, and conic gradients visually. Adjust colour stops, choose a colour space, and copy the CSS — everything runs in your browser.
How to use
Build your gradient in four steps
- 1 Choose a gradient type
Select Linear, Radial, or Conic from the switcher at the top. Each type has its own set of controls for angle, position, and shape.
- 2 Add and move colour stops
Drag the handles on the gradient track to position each stop. Double-click the track to add a new stop. Click a stop to open the colour picker.
- 3 Adjust angle and colour space
Set the angle with the numeric input or click a direction preset. Choose a colour space (sRGB, OKLCH, LCH, HSL) to control how colours blend.
- 4 Copy your CSS
The live CSS output updates instantly. Click Copy CSS to copy to clipboard, or use the Export menu for SVG download, Tailwind, and shareable links.
Frequently Asked Questions
What is the difference between linear, radial, and conic gradients?
What does "colour space" mean in CSS gradients?
sRGB is the default and most compatible. oklch and lch produce perceptually uniform blends with more vibrant midpoints. Specify it with the in <space> syntax: linear-gradient(in oklch, red, blue).Which browsers support conic gradients?
How does the WCAG contrast checker work?
Can I export my gradient as an SVG?
How do I use my gradient with Tailwind CSS?
bg-gradient-to-* utility with from-[..] and to-[..] colour stops is generated only for 2-stop linear gradients that use a keyword direction (e.g. "to right"). For all other gradients — 3 or more stops, a custom angle, radial, or conic — the tool generates a bg-[image:linear-gradient(…)] arbitrary-value class, plus a backgroundImage entry you can add to your tailwind.config.js.What is a shareable permalink?
What does OKHSV / OKHSL mean?
okhsv space, the generator maps these to oklch when writing the interpolation hint.Can I import an existing CSS gradient?
linear-gradient(), radial-gradient(), or conic-gradient() string (with or without the background: property) and click Import.