# Animated Strikethrough

> A marker line that slashes through old text, handy for sale prices and before-and-after copy.

- Category: [CSS Text Effects](https://copy-css.com/category/text)
- Tags: line-through, price, crossed out, sale, del
- Live preview: https://copy-css.com/snippets/animated-strikethrough
- License: Free for personal and commercial use. No signup, no attribution required.

## HTML

```html
<p class="strike-note">Was <s class="strike-line">$49</s> now $29</p>
```

## CSS

```css
.strike-note {
  margin: 0;
  color: #111827;
  font: 800 34px/1.3 system-ui, sans-serif;
}

.strike-line {
  position: relative;
  color: #6b7280;
  text-decoration: none;
}

.strike-line::after {
  content: "";
  position: absolute;
  top: 48%;
  left: -0.1em;
  right: -0.1em;
  height: 0.12em;
  border-radius: 1em;
  background: #e11d48;
  transform: rotate(-8deg) scaleX(0);
  transform-origin: left;
  animation: strike-line-draw 0.5s 0.4s ease-out forwards;
}

@keyframes strike-line-draw {
  to { transform: rotate(-8deg) scaleX(1); }
}

@media (prefers-reduced-motion: reduce) {
  .strike-line::after {
    animation: none;
    transform: rotate(-8deg);
  }
}
```

## Notes

- This CSS Animated Strikethrough is 36 lines of pure CSS (0.7 KB) with no JavaScript and no dependencies. It uses keyframe animations, transforms and reduced-motion support.
- In JSX use `className` instead of `class`. In Tailwind projects put the CSS in the global stylesheet.
