</> ConvertAtlas Developer Tools
Bootstrap 5 · Beginner

NPS Survey Scale

An 11-point NPS survey scale with contextual feedback.

Requires Bootstrap 5. 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>
<div class="card border-0 shadow-sm" style="max-width:360px"><div class="card-body">
  <h6 class="fw-bold mb-3">How likely to recommend us?</h6>
  <div class="d-flex justify-content-between gap-1 mb-2" id="npsWrap"></div>
  <div class="d-flex justify-content-between small text-secondary"><span>Not likely</span><span>Very likely</span></div>
  <div class="alert alert-success mt-3 mb-0 small" id="npsOut" style="display:none"></div>
</div></div>
var wrap=document.getElementById('npsWrap');
for(var i=0;i<=10;i++){(function(i){var b=document.createElement('button');b.className='btn btn-outline-secondary btn-sm flex-fill p-1';b.textContent=i;b.onclick=function(){wrap.querySelectorAll('button').forEach(function(x){x.className='btn btn-outline-secondary btn-sm flex-fill p-1'});b.className='btn btn-primary btn-sm flex-fill p-1';var o=document.getElementById('npsOut');o.style.display='block';o.textContent=i>=9?'🎉 Thanks! Glad you love it.':i>=7?'Thanks for your feedback!':'Sorry to hear — we will reach out.'};wrap.appendChild(b)})(i)}
Free to use.This component uses Bootstrap 5 (linked above). Copy any file, or download a ready-to-open .html page with the CDN links already included.