Preparing your generator page
We are loading content and tools so everything is ready to use.
We are loading content and tools so everything is ready to use.
Build a two-stop CSS gradient and copy it. Linear uses an angle from 0 to 360 degrees. Radial is a circle or an ellipse, always at the center. The page opens on linear-gradient(90deg, #3B82F6 0%, #EC4899 100%). In CSS, 90deg points right, so that blue sits on the left and that pink on the right. There is no third color, no alpha, and no conic gradient.
Convert a stop with the Color Code Generator. More helpers are in Utility tools.
Last updated: October 8, 2026 · Published: 2026-04-09 · Updated: 2026-10-08
Preview
Gradient value
linear-gradient(90deg, #3B82F6 0%, #EC4899 100%)
A CSS gradient is a background image the browser paints from color stops. You do not need an image file. linear-gradient() blends along a line. radial-gradient() blends outward from a center. This page writes one of those functions with exactly two stops.
The preview and the monospace value use the same string. Copy gradient takes that function. Copy CSS snippet wraps it:
.my-gradient-element {
background: linear-gradient(90deg, #3B82F6 0%, #EC4899 100%);
}Rename .my-gradient-element. The property is background, so the rule clears other background layers on that element. Put the function on background-image if you need to keep a separate background color.
Four steps from the default blue-to-pink blend to a rule in your stylesheet.
Linear uses an angle. Radial uses circle or ellipse, always at the center.
Pickers store #RRGGBB. Stops are percents. The fade runs from stop 1 to stop 2.
The swatch uses the same background value as the monospace line under it.
Copy gradient for the function alone. Copy CSS snippet for a .my-gradient-element rule. Rename that class.
What the copied CSS can contain.
| Setting | This generator |
|---|---|
| Types | linear-gradient and radial-gradient only |
| Stops | Exactly two, each 0–100% |
| Default | linear-gradient(90deg, #3B82F6 0%, #EC4899 100%) |
| Angle | 0–360 degrees; 0deg is up; 90deg is right |
| Radial | circle or ellipse, always at center |
| Colors | Opaque #RRGGBB from a color picker |
| Not included | Conic, repeating, alpha, a third stop, position keywords |
| Snippet class | .my-gradient-element |
| Property | background, which replaces the whole shorthand |
| Prefixes | None |
Two colors, two positions, and either an angle or a shape.
Linear is the default. Switching to radial hides the angle and shows circle or ellipse.
Degrees clockwise from up. Default 90, which runs left to right. Shown only for linear.
The radial shape. Always “at center.” Circle is the default shape when you switch to radial.
Two opaque hex colors. Defaults #3B82F6 and #EC4899. No alpha and no third stop.
Positions from 0 to 100. Defaults 0 and 100. Random keeps stop 2 at 40 or higher.
New colors, angle, and stops. Leaves linear versus radial, and circle versus ellipse, as they are.
CSS measures the linear angle clockwise from the top, not from the left.
| Angle | Points | Where the two colors sit |
|---|---|---|
| 0deg | Up | First color at the bottom, second at the top |
| 90deg | Right | First color on the left, second on the right (the default) |
| 180deg | Down | First color at the top, second at the bottom |
| 270deg | Left | First color on the right, second on the left |
| 360deg | Up | Same direction as 0deg |
Radial ignores that table. circle keeps a round fade. ellipse follows the box, so a wide element stretches the fade sideways. Both are fixed at center.
Stop 1 places #3B82F6 unless you change the picker. Stop 2 places #EC4899. Those defaults are blue and pink with no transparency. The browser blends the gap between the two percents. Before the first stop and after the second, it holds that stop’s color.
If you set stop 2 lower than stop 1, the CSS cascade of stops does not run the fade backward. The second position is raised to the first, and the two colors meet at one point. That is a hard edge. Random gradient avoids that pair: its first stop is 0–39 and its second is 40–100.
Random gradient also replaces both colors with any of the 16,777,216 opaque sRGB values and sets a new angle. It leaves the type and the radial shape alone. Nothing is stored on Muxgen.
Short definitions for the words on this page.
A blend along a straight line. This page writes linear-gradient(angle, color stop, color stop).
A blend outward from the center. This page writes circle or ellipse at center, with two stops.
A color pinned to a percent along the gradient line. This tool has two stops.
The direction of a linear gradient in degrees. 0deg is up and angles grow clockwise.
The CSS property the snippet sets. It replaces background color, image, repeat, and position together.
A sweep around a center. This generator does not produce conic-gradient().
The default 90deg blend, angles, radial center, stops, the two copy buttons, and what this page does not generate.
Explore more tools in the directory.
Convert a stop’s HEX to RGB or HSL before you match the picker.
Nearest CSS color name and contrast notes for a hex you already have.
Glow text treatments after you have chosen a pair of colors.
A flat QR color, separate from a gradient background.