<label class="switch">
  <input class="ch" type="checkbox" />
  <span class="slider"></span>
</label>

<style>
/* From Uiverse.io by ercnersoy  - Tags: simple, switch, creative */
/* The switch - the box around the slider */
.switch {
  font-size: 17px;
  position: relative;
  display: inline-block;
  width: 3.5em;
  height: 1.5em;
}
/* Hide default HTML checkbox */
.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}
/* The slider */
.slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  back