CSS Gradient Generator: Linear, Radial and Conic

Build a CSS gradient with up to eight stops, per-stop opacity and presets, then copy CSS, SCSS or a Tailwind class.

Loading tool…

How to use the CSS Gradient Generator

  1. Pick a preset or Random, or choose linear, radial or conic.
  2. Set the angle, shape, size and centre, and tick Repeating if you want a repeating gradient.
  3. Drag stops on the bar (or use arrow keys), edit colours, positions and opacity.
  4. Copy CSS, SCSS or Tailwind, or download a PNG. You can also import an existing gradient.

About this tool

A CSS gradient is an image generated by the browser, so it needs no file and scales to any size. A linear gradient blends colours along a straight line at an angle. A radial gradient spreads outward from a centre point, as a circle or ellipse, and its size keyword (closest-side, farthest-corner and so on) controls how far it reaches. A conic gradient sweeps colours around a centre, like a colour wheel or pie chart. Repeating gradients tile the stop pattern every N percent.

Each colour stop has a colour, a position from 0 to 100 percent and an opacity; stops with opacity below 100 are written as rgba(). Stops are sorted by position in the output, and two stops at the same position make a hard edge. Output formats are plain CSS (with an optional solid-colour fallback line), an SCSS variable, and a Tailwind arbitrary-value class (plus the bg-gradient-to-* and v4 bg-linear-to-* forms when the gradient is a simple evenly spaced linear one).

Gradients work unprefixed in all current browsers, so no -webkit- versions are generated. The PNG download draws a 1200 x 630 image (handy for social cards); repeating gradients are drawn once. Check text contrast on top of a gradient, since the lightest part can reduce readability.

Frequently asked questions

What is the difference between linear, radial and conic gradients?

Linear blends along a line, radial spreads out from a point, and conic rotates colours around a point.

How do I make a hard colour edge?

Give two neighbouring stops the same position.

How many colour stops can I add?

Up to eight here. CSS itself allows many more.

Can I edit an existing gradient?

Yes. Open Import an existing CSS gradient, paste the value and load it into the editor.

Do gradients work in all browsers?

All current browsers support all three types, unprefixed.

Need a custom tool or website?

IDM Valley builds web apps, calculators, AI chatbots and automation for businesses. Fixed prices, code in your name.

Get a free quote

Have a project in mind?

Tell us what you need: a website, landing page, AI chatbot or automation. You get a clear scope and a fixed price within one working day. Free, no obligation.


  • avshack
  • DivineBamboo
  • goldleaf
  • janapril
  • kaizen
  • kwc
  • modv
  • pixelrush
  • revital
  • riderzplanet
  • sandsfashions
  • avshack
  • DivineBamboo
  • goldleaf
  • janapril
  • kaizen
  • kwc
  • modv
  • pixelrush
  • revital
  • riderzplanet
  • sandsfashions