Logocolorspicker.net

Gradient generator

Angle°
CSSbackground: linear-gradient(90deg, #0f37ff 0%, #5cbeff 100%);

Colors2

  • %
  • %

Gradient color palette

Free online gradient maker

Pick two or more colors, set their positions, and watch the gradient change as you work. The gradient generator writes the CSS for you, and you can also save the result as a PNG or SVG image.

A gradient is a smooth change from one color to another. You may also know it as a color fade, a color transition, a color gradation or ombre: they all mean the same thing here.

Everything runs in your browser: no account, nothing to install, and your last gradient is still here when you come back.

How to make a gradient

  1. Pick a starting point. Press "Random", choose a ready-made gradient from the gallery, or press "From image" to make a color gradient from a picture.
  2. Set the colors. Click a circle on the strip to change its color, drag it to move it, or click between circles to add one more.
  3. Choose the type. Linear, radial or conic. Turn the dial to set the angle, or press "Reverse" to swap the ends.
  4. Save the result. Copy the CSS, or download a PNG for desktop or phone, or an SVG.

Gradient color palette and HEX codes

Under the editor, your gradient is split into even steps, from 3 to 16. This is the gradient color palette: click a step to copy its HEX code, or copy all the codes at once for a chart, a map or a design system.

Gradient wallpaper for a desktop or a phone

Open a gradient you like and press "PNG" for a 1920x1080 desktop wallpaper, or "Phone" for a tall 1440x3120 one. Press "Full screen" first to see how it looks on the whole screen.

Best gradient color combinations

Neighbors on the wheel. Blue with purple, pink with orange, green with yellow. They never turn gray in the middle.

Light and dark of one color. Calm enough to put text on, which makes it good for a page background.

Three colors in a row. Yellow, pink and purple look like a sunset, and many cool gradients are built this way.

CSS linear gradient

A linear gradient runs along a straight line. The angle sets its direction: 0deg is up, 90deg is to the right, 180deg is down. Without an angle, the browser uses 180deg. The percentages set where each color sits.

background: linear-gradient(90deg, #7b2ff7 0%, #f107a3 100%);

Instead of an angle you can write a side or a corner, such as "to right" or "to bottom right". In a square, "to bottom right" and 135deg look the same. In a wide block they differ: with the corner version the middle color always meets the other two corners.

CSS radial gradient

A radial gradient spreads out from one point in circles. "circle" keeps it round; without it, the gradient stretches into an ellipse that matches the shape of the block. Add "at top left" to move the center out of the middle.

background: radial-gradient(circle at top left, #ffd166 0%, #ff5a36 100%);

CSS conic gradient

A conic gradient turns around a point, like the hand of a clock. Use it for color wheels and pie charts. Repeat the first color at the end so there is no hard line where the circle closes.

background: conic-gradient(from 0deg, #ff3b30, #ffd60a, #34c759, #0a84ff, #af52de, #ff3b30);
border-radius: 50%;

Gradient background for a whole page

Apply the gradient to the body and make it as tall as the window. Otherwise, a short page gets a gradient that ends early and starts again below.

body {
  min-height: 100vh;
  margin: 0;
  background: linear-gradient(180deg, #4facfe 0%, #c2f0ff 100%);
}

Gradient text and gradient border

For gradient text, clip the background to the shape of the letters and make the letters themselves transparent.

Gradient text
background: linear-gradient(90deg, #ff2d6f, #7b2ff7);
-webkit-background-clip: text;
background-clip: text;
color: transparent;

For a gradient border with rounded corners, draw two backgrounds: the fill inside, and the gradient under a transparent border.

border: 4px solid transparent;
border-radius: 12px;
background:
  linear-gradient(#fff, #fff) padding-box,
  linear-gradient(90deg, #00b894, #0a84ff) border-box;

Frequently asked questions

Why is the middle of my gradient gray?

Opposite colors, such as blue and yellow, pass through gray on the way to each other. Add a third color between them, or choose neighbors on the color wheel, such as blue and purple.

How many colors can a gradient have?

At least two, and this gradient creator sets no upper limit. Two to four usually look the smoothest.

Can I make a gradient from an image?

Yes. Press "From image" and choose a file. The tool picks up to four main colors and puts them in order from dark to light. The image stays on your device.

How do I download a gradient as an image?

Press "PNG" for a 1920x1080 gradient background image, "Phone" for a tall wallpaper, or "SVG" for an image that stays sharp at any size. Conic gradients are saved as PNG only, because SVG has no conic gradients.

Why do I see stripes instead of a smooth change?

Two close colors stretched over a large area have only a few shades between them, and each shade becomes a visible band. Choose colors that differ more, or make the area smaller.

Do CSS gradients work in every browser?

Linear and radial gradients work in every browser in use today. Conic gradients work in Chrome, Edge, Safari and Firefox, in versions released since late 2020.

More color tools

To choose a single color or take one from a photo, use the color picker from image. To find colors that match, use the color wheel.

Gradient Maker & Generator | CSS Gradient Background