# Segmented Spinner

> A system-style spinner with fading segments, drawn from one element with a conic gradient and a mask.

- Category: [CSS Loaders & Spinners](https://copy-css.com/category/loaders)
- Tags: spinner, ios, segments, conic, mask, loading
- Live preview: https://copy-css.com/snippets/segmented-spinner
- License: Free for personal and commercial use. No signup, no attribution required.

## HTML

```html
<div class="spinner-seg" role="status" aria-label="Loading"></div>
```

## CSS

```css
.spinner-seg {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: conic-gradient(rgba(14, 165, 233, 0.08), #0ea5e9);
  -webkit-mask:
    radial-gradient(farthest-side, transparent 52%, #000 54%),
    repeating-conic-gradient(#000 0 20deg, transparent 0 30deg);
  -webkit-mask-composite: source-in;
  mask:
    radial-gradient(farthest-side, transparent 52%, #000 54%),
    repeating-conic-gradient(#000 0 20deg, transparent 0 30deg);
  mask-composite: intersect;
  animation: spinner-seg 1s steps(12) infinite;
}

@keyframes spinner-seg {
  to { transform: rotate(1turn); }
}

@media (prefers-reduced-motion: reduce) {
  .spinner-seg {
    animation-duration: 2s;
  }
}
```

## Notes

- This CSS Segmented Spinner is 25 lines of pure CSS (0.7 KB) with no JavaScript and no dependencies. It uses keyframe animations, transforms, radial gradients and conic gradients.
- In JSX use `className` instead of `class`. In Tailwind projects put the CSS in the global stylesheet.
