12 CSS Progress Bar Designs

Step Tracker

Numbered steps with a connecting rail that fills as you progress. Completed steps morph into checkmarks via pseudo-elements — ideal for checkout flows, onboarding wizards, and multi-page forms.

Pure CSS MIT licensed

Step Tracker the 2nd of 12 designs in the 12 CSS Progress Bar Designs collection. The design is implemented in pure CSS — no JavaScript required. Copy the HTML and CSS panels below into your project. Because the demo is pure CSS, it works in any framework or templating engine you happen to use. The design honours prefers-reduced-motion and uses real semantic markup, so it ships accessibility-ready out of the box.

Live preview

Open in playground

The code

<ol class="pb-step" role="list" data-current="3">
  <li class="pb-step-item is-done"><span>1</span><em>Cart</em></li>
  <li class="pb-step-item is-done"><span>2</span><em>Address</em></li>
  <li class="pb-step-item is-current"><span>3</span><em>Payment</em></li>
  <li class="pb-step-item"><span>4</span><em>Confirm</em></li>
</ol>
.pb-step {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  width: 280px;
  list-style: none;
  margin: 0;
  padding: 0;
  font-family: system-ui, sans-serif;
  isolation: isolate;
}

.pb-step::before,
.pb-step::after {
  content: "";
  position: absolute;
  left: 12.5%;
  right: 12.5%;
  top: 15px;
  height: 2px;
  border-radius: 2px;
  z-index: 0;
}

.pb-step::before {
  background: rgba(255, 255, 255, 0.08);
}

.pb-step::after {
  background: linear-gradient(90deg, #14b8a6, #2dd4bf);
  width: 0;
  left: 12.5%;
  right: auto;
  transition: width 0.5s cubic-bezier(0.5, 0, 0.3, 1.2);
}

.pb-step[data-current="2"]::after {
  width: calc(((2 - 1) / (4 - 1)) * 75%);
}

.pb-step[data-current="3"]::after {
  width: calc(((3 - 1) / (4 - 1)) * 75%);
}

.pb-step[data-current="4"]::after {
  width: 75%;
}

.pb-step-item {
  position: relative;
  display: grid;
  gap: 6px;
  place-items: center;
  font-size: 11px;
  color: #94a3b8;
  z-index: 1;
}

.pb-step-item span {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #1e293b;
  border: 2px solid rgba(255, 255, 255, 0.08);
  color: #94a3b8;
  font-weight: 700;
  font-size: 13px;
  transition:
    background 0.3s,
    border-color 0.3s,
    color 0.3s;
  position: relative;
}

.pb-step-item em {
  font-style: normal;
  font-size: 10.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 600;
}

.pb-step-item.is-done span,
.pb-step-item.is-current span {
  background: linear-gradient(135deg, #14b8a6, #2dd4bf);
  border-color: #2dd4bf;
  color: #0f172a;
  box-shadow: 0 0 0 4px rgba(20, 184, 166, 0.15);
}

.pb-step-item.is-done span {
  font-size: 0;
}

.pb-step-item.is-done span::before {
  content: "";
  width: 13px;
  height: 7px;
  border: 2px solid #0f172a;
  border-top: 0;
  border-right: 0;
  transform: rotate(-45deg);
  transform-origin: center;
}

.pb-step-item.is-current em {
  color: #2dd4bf;
}

.pb-step-item.is-done em {
  color: #cbd5e1;
}

Search CodeFronts

Loading…