Skip to main content

A CSS-only Zig-Zag edge

How much code is needed to create a Zig-Zag edge?

Use an online generator to easily get the code:

A CSS-only zig-zag border

.zig-zag {
mask: conic-gradient(from -45deg at bottom,#000 90deg,#0000 0) 50% / 60px 100%;

See the Pen CSS only Zig-Zag edge by Temani Afif (@t_afif) on CodePen.

More detail: