# Corner Ribbon

> A diagonal "NEW" ribbon across the corner of a card.

- Category: [CSS Effects](https://copy-css.com/category/effects)
- Tags: ribbon, badge, corner, new, label
- Live preview: https://copy-css.com/snippets/corner-ribbon
- License: Free for personal and commercial use. No signup, no attribution required.

## HTML

```html
<div class="ribbon-box">
  <span class="ribbon">New</span>
</div>
```

## CSS

```css
.ribbon-box {
  position: relative;
  overflow: hidden;
  width: 180px;
  height: 120px;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
}

.ribbon {
  position: absolute;
  top: 18px;
  right: -34px;
  width: 120px;
  padding: 6px 0;
  background: #ef4444;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
  color: #fff;
  font: 800 12px/1 system-ui, sans-serif;
  letter-spacing: 0.1em;
  text-align: center;
  text-transform: uppercase;
  transform: rotate(45deg);
}
```

## Notes

- This CSS Corner Ribbon is 25 lines of pure CSS (0.5 KB) with no JavaScript and no dependencies. It uses transforms and box shadows.
- In JSX use `className` instead of `class`. In Tailwind projects put the CSS in the global stylesheet.
