# Gradient Text

> Headline text filled with a gradient using background-clip: text.

- Category: [CSS Text Effects](https://copy-css.com/category/text)
- Tags: gradient, heading, background-clip, colorful
- Live preview: https://copy-css.com/snippets/gradient-text
- License: Free for personal and commercial use. No signup, no attribution required.

## HTML

```html
<h2 class="text-gradient">Make it pop</h2>
```

## CSS

```css
.text-gradient {
  margin: 0;
  font: 800 44px/1.1 system-ui, sans-serif;
  background: linear-gradient(90deg, #f97316, #ec4899, #8b5cf6);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
```

## Notes

- This CSS Gradient Text is 8 lines of pure CSS (0.2 KB) with no JavaScript and no dependencies. It uses linear gradients and gradient-clipped text.
- gradient-clipped text: Includes the -webkit- prefix Safari still needs.
- In JSX use `className` instead of `class`. In Tailwind projects put the CSS in the global stylesheet.
