Design and security
CSS gradient
Choose the type, the colors and the angle. The preview and the CSS follow at once.
How to use it
- Choose linear or radial. For a linear gradient, set the angle.
- Pick the colors and move their positions.
- Copy the CSS and paste it into background.
A gradient is a background that moves from one color to another. In CSS that is one value: the direction, then each color with its position. Linear runs along a line. Radial spreads from the center outward.
Two colors are enough for most backgrounds. Add another when you want a band in the middle. The position is a percentage from the start of the gradient to the end. Copy the value into the background property.
Questions
Where do I paste the value?
Into the background property, for example background: linear-gradient(135deg, #2f6fed 0%, #f7b4d4 100%).
What does the angle do?
It turns a linear gradient. 0° runs upward, 90° to the right, and 180° downward.
Can I use more than two colors?
Yes. Add up to five. Each one needs a position from 0 to 100.