# Outline Text

> Hollow outlined headline text that fills in solid on hover.

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

## HTML

```html
<h2 class="text-outline">OUTLINE</h2>
```

## CSS

```css
.text-outline {
  margin: 0;
  font: 900 52px/1 system-ui, sans-serif;
  letter-spacing: 0.02em;
  color: transparent;
  -webkit-text-stroke: 2px #111;
  transition: color 0.3s ease;
}

.text-outline:hover {
  color: #111;
}
```

## Notes

- This CSS Outline Text is 12 lines of pure CSS (0.2 KB) with no JavaScript and no dependencies. It uses transitions.
- In JSX use `className` instead of `class`. In Tailwind projects put the CSS in the global stylesheet.
