Home โบ Developer Tools โบ CSS Gradient Generator
๐ CSS Gradient Generator
Blend two colors into a linear or radial CSS gradient with a live preview and code.
About this CSS Gradient Generator
Gradients add depth and polish to buttons, banners and backgrounds without any image files. This generator blends two colors into a linear gradient at any angle, or a radial gradient that glows from the center, previews the result live, and writes the exact CSS background declaration for you to paste into your stylesheet.
How to use it
- Pick the first and second colors with the color swatches.
- Drag the angle slider to set the direction of a linear gradient.
- Switch Type to Radial if you prefer a center glow.
- Copy the CSS code and paste it into your project.
Example
With the default colors and a 135ยฐ angle, the generated code is background: linear-gradient(135deg, #ff5f6d, #ffc371); โ a warm coral-to-peach diagonal blend.
Frequently asked questions
Does the angle apply to radial gradients?
No. Angle only affects linear gradients. A radial gradient always spreads outward from the center of the element.
Can I use the result in a button?
Yes โ paste the declaration into any CSS rule. Gradients work on buttons, headers, cards and whole page backgrounds.
Why use CSS instead of an image?
CSS gradients are resolution-independent, weigh almost nothing, and load instantly โ no image request, no blur on high-density screens.
More Developer Tools
Password Generator
Create strong random passwords in your browser with a live entropy strength meter.
QR Code Generator
Turn any text or link into a QR code you can save โ generated right in your browser.
Base64 Encoder & Decoder
Encode text to Base64 or decode Base64 back, with safe UTF-8 handling for any language.
JSON Formatter
Format, minify and validate JSON, with clear error positions and quick structure stats.
URL Encoder & Decoder
Encode or decode URLs and query text safely, with component or full-URL modes.
JSON to CSV Converter
Convert a JSON array of objects to CSV, or turn CSV back into clean JSON.