<h1>Pure CSS Spinner</h1>
<div class="spinner">
  <div class="spinner-inner"></div>
</div>
* {
  font-family: sans-serif;
  box-sizing: border-box;
}

.spinner {
  position: relative;
  width: 50px;
  height: 50px;
  border: 5px solid #efefef;
  border-radius: 50%;
}
.spinner-inner {
  position: absolute;
  top: -5px;
  right: -5px;
  bottom: -5px;
  left: -5px;
  border-radius: 50%;
  border-width: 5px;
  border-style: solid;
  border-color: #333 transparent transparent transparent;
  border-radius: 50%;
  animation: infinite-spinning 1s linear infinite;
}

@keyframes infinite-spinning {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

@-webkit-keyframes infinite-spinning {
  from {
    -webkit-transform: rotate(0deg);
  }
  to {
    -webkit-transform: rotate(360deg);
  }
}

External CSS

This Pen doesn't use any external CSS resources.

External JavaScript

This Pen doesn't use any external JavaScript resources.