CSS Gradient Generator
Compose linear, radial or conic gradients with editable color stops, positions and angle; copy the represented CSS or supported Tailwind value.
Keep typing the HEX draft; a valid #fff expands in the result. Leaving the field normalizes valid input. Incomplete or invalid input clears the result.
Check the gradient: enter valid HEX colors, an angle from 0 to 360 and stop positions from 0 to 100.
Type
Presets
Color Stops ()
Copied
Copy failed. Select the result and copy it manually.
Method and interpretation
CSS serializes every chosen stop in order. Linear uses the selected angle, radial uses circle, and conic uses the selected starting angle. The preview reads the same gradient string as CSS.
Positions range from 0% to 100%; at least two stops remain. 90° linear runs left to right, 180° top to bottom. Equal stop positions may create a hard transition.
Stop percentages and angle are serialized as their numeric values; no color interpolation is calculated by this tool. Browser painting determines the intermediate colors.
About CSS Gradient Generator
Compose linear, radial or conic gradients with editable color stops, positions and angle; copy the represented CSS or supported Tailwind value.
A color stop binds one opaque HEX color to a percentage. Add, remove or sort stops, or start from one of eight presets and randomize. Linear gradients follow an angle; radial gradients spread from a circle; conic gradients turn around a center.
Linear 90°, #000000 at 0% and #ffffff at 100% gives background: linear-gradient(90deg, #000000 0%, #ffffff 100%);. At 180° and 20%/80%, both values remain in supported Tailwind output.
Calculations use the values in this page without a tool-specific server request. These tools keep no result history or favorites. The site theme may be read from localStorage; the surrounding site can make its own requests.
Use Cases
How to use
Choose Linear, Radial or Conic.
Set the angle for Linear or Conic; Radial uses a circle.
Edit each HEX color and percentage; add or remove stops while keeping at least two.
Sort stops after position changes or apply one of the eight presets, then inspect the preview.
Copy CSS, or copy Tailwind only when supported; use CSS for four-stop or non-linear output.
Pro Tips
- Compare the selected direction and stop percentages before copying. CSS is the complete representation; a CSS guidance message in the Tailwind panel is not a usable class.
- Tailwind output supports two or three linear stops using an arbitrary-value class that preserves angle and positions. Four or more stops, radial and conic explicitly require CSS here. Your target project must scan or include the class, and actual browser support must be checked.
- Start with a few colors for a restrained gradient, and inspect it at different screen sizes in your destination layout.
Troubleshooting
Check the gradient: enter valid HEX colors, an angle from 0 to 360 and stop positions from 0 to 100.
Positions range from 0% to 100%; at least two stops remain. 90° linear runs left to right, 180° top to bottom. Equal stop positions may create a hard transition. Keep typing the HEX draft; a valid #fff expands in the result. Leaving the field normalizes valid input. Incomplete or invalid input clears the result.
Copy unavailable. Select the displayed result and copy it manually.
Compare the selected direction and stop percentages before copying. CSS is the complete representation; a CSS guidance message in the Tailwind panel is not a usable class.
Frequently Asked Questions
The color is reached at 20% of the gradient progression. Stop positions affect the transition; they are preserved in both CSS and the supported Tailwind class.
This helper handles only two or three linear stops. Radial, conic or four-stop gradients remain available in preview and CSS; they are not replaced with an inaccurate rightward gradient.
A point in the gradient where a specific color is placed. More stops = more colors.
Linear flows in a direction, radial radiates from a center point.