</> ConvertAtlas Developer Tools
Bootstrap 5 · Advanced

Order Checkout Wizard

A multi-step order flow with a masked card field, via Cleave.

Requires Bootstrap 5, Cleave.js. Add the CDN tags below to your page (styles in <head>, scripts before </body>). The downloaded file already includes them.
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/css/bootstrap.min.css">
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/js/bootstrap.bundle.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/cleave.js@1.6.0/dist/cleave.min.js"></script>
<div class="card border-0 shadow-sm" style="max-width:380px"><div class="card-body">
  <div class="progress mb-3" style="height:5px"><div class="progress-bar" id="owBar" style="width:33%"></div></div>
  <div data-ow="0"><h6 class="fw-bold">Shipping</h6><input class="form-control mb-2" placeholder="Address"></div>
  <div data-ow="1" style="display:none"><h6 class="fw-bold">Payment</h6><input class="form-control mb-2" id="owCard" placeholder="Card number"></div>
  <div data-ow="2" style="display:none"><h6 class="fw-bold text-success">Confirmed ✓</h6><p class="small text-secondary">Order placed successfully.</p></div>
  <div class="d-flex justify-content-between"><button class="btn btn-light btn-sm" id="owBack">Back</button><button class="btn btn-primary btn-sm" id="owNext">Next</button></div>
</div></div>
var steps=document.querySelectorAll('[data-ow]'),bar=document.getElementById('owBar'),i=0,carded=false;
function show(){steps.forEach(function(s,k){s.style.display=k===i?'block':'none'});bar.style.width=((i+1)/steps.length*100)+'%';document.getElementById('owNext').textContent=i===steps.length-1?'Done':'Next';if(i===1&&!carded){carded=true;new Cleave('#owCard',{creditCard:true})}}
document.getElementById('owNext').onclick=function(){if(i<steps.length-1){i++;show()}};
document.getElementById('owBack').onclick=function(){if(i>0){i--;show()}};
Free to use.This component uses Bootstrap 5, Cleave.js (linked above). Copy any file, or download a ready-to-open .html page with the CDN links already included.