CSS gradients add visual depth and interest without image files. A complete guide to linear, radial, and conic gradients with a syntax reference table and design pattern suggestions.
CSS gradients are one of the most versatile and underused design tools available to web developers. From subtle background washes to bold hero sections, gradients add depth and visual interest without a single image file. The CSS syntax is flexible but unintuitive to write by hand — a visual gradient generator gives you production-ready CSS instantly.
CSS supports three main gradient types, each with different geometry:
linear-gradient()) — Transitions colours along a straight line in any direction. The most commonly used type. You specify a direction (e.g. to right, 45deg) and a list of colour stops.radial-gradient()) — Radiates outward from a central point in circles or ellipses. Creates spotlight effects, glows, and soft spotlight backgrounds.conic-gradient()) — Rotates colour stops around a central point, like the segments of a pie chart. Used for pie chart illustrations and colour wheel designs.| Gradient type | CSS example |
|---|---|
| Two-colour linear (L to R) | linear-gradient(to right, #667eea, #764ba2) |
| Diagonal (45 degrees) | linear-gradient(45deg, #f093fb, #f5576c) |
| Three-colour linear | linear-gradient(to bottom, #4facfe, #00f2fe, #43e97b) |
| Radial from centre | radial-gradient(circle, #a18cd1, #fbc2eb) |
| Radial off-centre | radial-gradient(circle at 30% 40%, #f7971e, #ffd200) |
| Hard stop (no blend) | linear-gradient(to right, #ff0000 50%, #0000ff 50%) |
:hover using CSS transitions for a polished interactive effect.background-clip: text and-webkit-background-clip: text with a gradient as the text fill colour for eye-catching headline typography.The most cohesive gradients come from your existing brand palette. Extract your brand colours using the Color Palette Extractor and use those hex codes as gradient stops. Convert colours between formats (hex, HSL, RGB) as needed with the Color Picker & Converter to get the exact values you need.
CSS gradients are a powerful, zero-image-weight design tool that every web developer and designer should have in their toolkit. The ToolsGravity CSS Gradient Generator gives you a visual, interactive interface for creating linear, radial, and conic gradients with any number of colour stops — and outputs production-ready CSS you can copy with one click. Combine it with your brand palette and the CSS is ready for your stylesheet immediately.