# Material Spinner

> The Material Design circular spinner: an SVG arc that grows and shrinks while it rotates.

- Category: [CSS Loaders & Spinners](https://copy-css.com/category/loaders)
- Tags: svg, stroke-dasharray, android, circular, indeterminate
- Live preview: https://copy-css.com/snippets/material-spinner
- License: Free for personal and commercial use. No signup, no attribution required.

## HTML

```html
<svg class="spinner-material" viewBox="0 0 50 50" role="status" aria-label="Loading">
  <circle cx="25" cy="25" r="20"/>
</svg>
```

## CSS

```css
.spinner-material {
  width: 48px;
  height: 48px;
  animation: spinner-material-rotate 2s linear infinite;
}

.spinner-material circle {
  fill: none;
  stroke: #2563eb;
  stroke-width: 4;
  stroke-linecap: round;
  stroke-dasharray: 1 150;
  animation: spinner-material-dash 1.5s ease-in-out infinite;
}

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

@keyframes spinner-material-dash {
  0% { stroke-dasharray: 1 150; stroke-dashoffset: 0; }
  50% { stroke-dasharray: 90 150; stroke-dashoffset: -35; }
  100% { stroke-dasharray: 90 150; stroke-dashoffset: -124; }
}

@media (prefers-reduced-motion: reduce) {
  .spinner-material { animation-duration: 4s; }
  .spinner-material circle { animation: none; stroke-dasharray: 90 150; }
}
```

## Notes

- This CSS Material Spinner is 29 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.
