Seven ways to end a section with something softer than a straight line: an SVG wave, three layered waves for depth, a scalloped edge cut with a mask, a band with waves on both edges, a slowly moving wave, a zigzag strip and a single shallow curve.
A section that ends in a smooth wave instead of a straight line. The wave is an inline SVG path stretched with preserveAspectRatio="none", filled with the next section's colour, so the two blocks flow into each other.
Three wave layers in falling opacity give the divider depth. All three paths sit in one SVG, each a little offset, and the last one matches the colour of the section below so the edge looks finished.
A scalloped bottom edge with no SVG: a mask made of a repeating radial gradient bites round notches out of the section's edge. Change the circle size in the gradient to change the scallops.
View code
<section class="wv3"><h3>Sweet things</h3><p>Fresh pastries every morning.</p></section>
A coloured band with waves on both edges, a soft way to break up a long page. The same SVG is used twice, the top copy flipped with scaleY(-1), so there is only one shape to maintain.
The wave along the bottom of the section shifts slowly sideways, a little life for a hero without distraction. The path is twice as wide as the view and seamless, so translating it by half loops perfectly; it is still under reduced motion.
A sharp zigzag edge made with two linear gradients at 45 degrees as a repeating background along a thin strip. It is pure CSS, tiles to any width and looks at home on playful or retro designs.
View code
<div class="wv6"><section><h3>Summer sale</h3></section><div class="zz" aria-hidden="true"></div><section class="b"><p>Up to 40% off outdoor gear.</p></section></div>
The calmest divider: one wide, shallow curve made by giving a pseudo-element an elliptical border radius larger than the section. No SVG is needed, and the curve stays smooth at any width because its radius is a percentage.
View code
<section class="wv7"><h3>Our story</h3><p>From a market stall to a studio of six.</p></section>
A wave is an SVG path inside a viewBox with preserveAspectRatio="none", so it stretches to any width. Fill it with the colour of the next section and the two blocks flow together.
Masks for repeating edges
Scallops and other repeating edges can be cut from a section with a CSS mask made of repeating gradients. No extra element is needed, and the edge works over images too.
Decorative only
Dividers carry no meaning, so the SVG gets aria-hidden="true". Keep the content and headings in the sections themselves.
Mind the seams
Tiny gaps can appear between an SVG and the next section on some screens. Set display: block on the svg, and give it the next section's background colour as a safety net.
Frequently asked questions
Where can I get different wave shapes?
Edit the path's control points, or use the wave generator in this library to design one and copy the SVG.
Will waves slow down the page?
No. An inline SVG path is a few hundred bytes and renders instantly.
Can I put a wave on top of a section?
Yes. Flip the same SVG with transform: scaleY(-1), as the top-and-bottom demo does.