Linear Gradient Generator

Build CSS linear gradients and copy the code instantly.

Processed locally — nothing is uploaded

About CSS Gradient Generator

Add and drag colour stops, set the angle, and switch between the three gradient types while watching the result, then copy CSS ready to paste into a stylesheet. Conic gradients in particular are far quicker to dial in by eye than by hand.

Design a CSS linear gradient with a live preview, custom colour stops and an adjustable angle, then copy production-ready CSS. It renders in your browser.

This CSS gradient generator lets you design linear, radial and conic gradients visually and copy the exact CSS to paste into any project. Add as many colour stops as you like, pick each colour, drag its position along the track, and set the angle — the live preview updates as you go, so you can dial in the look before touching your stylesheet.

Gradients are one of the easiest ways to add depth to buttons, hero sections and backgrounds without images, which keeps pages fast. The output is plain CSS you can paste anywhere — no build step, no library, and nothing that has to stay in sync.

Learn how this works

Frequently asked questions

How does the angle work in CSS?

0deg points upward and angles increase clockwise, so 90deg runs left to right and 180deg top to bottom. This differs from the mathematical convention, which is why gradients often appear rotated from what you expected.

Why does my gradient look muddy in the middle?

Because interpolation between complementary colours passes through grey. Adding an intermediate colour stop in a hue you actually want avoids the dead zone — a blue-to-orange fade is the classic offender.

Can I use more than two colours?

Yes, CSS accepts any number of stops with optional positions. Restraint helps though: past three or four the result usually reads as noisy rather than rich.

Common Use Cases

  • Building a hero or button background without a design tool
  • Matching an existing gradient from a brand guideline
  • Experimenting with colour stops and copying the CSS out

More CSS Gradient Generator tools

Related tools