A worked example, rendered from real sample data. Sign in to run the tool on your own input.
accent=#10b981 size=20px.check { position: relative; display: inline-flex; align-items: center; gap: 8px; cursor: pointer; }
.check input { position: absolute; opacity: 0; width: 0; height: 0; }
.check .box { width: 20px; height: 20px; border: 2px solid #d1d5db; border-radius: 4px; transition: all 150ms ease; }
.check input:checked + .box { background: #10b981; border-color: #10b981; }
.check input:checked + .box::after { content: ''; display: block; width: 5px; height: 10px; margin: 2px auto 0; border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg); }
Build a custom checkbox with CSS-only checkmark — accent & size control. Part of the DevTools Surf developer suite. Browse more tools in the CSS collection.