CSS Wave Generator

Free toolNo sign-up
Contrast7.03:1
WAVE FAMILYSINE
LAYERS1 of 4
SHAPE
Amplitude
px
Frequency
cy
Phase
°
Opacity
Stroke
px
Invert layer
GEOMETRY
Width
px
Height
px
Baseline
px
Fill
COLOR
TURBULENCE
Amount
Detail
PREVIEW ON
RESPONSIVE
2.36 KBlive
1440 × 200
PRESETS
4 lines · 2.37 KB
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 200" preserveAspectRatio="none" width="100%" height="100%" style="display:block" aria-hidden="true" focusable="false">
<path d="M 0.00 100.00 C 15.00 100.00 15.00 110.35 30.00 110.35 C 45.00 110.35 45.00 120.00 60.00 120.00 C 75.00 120.00 75.00 128.28 90.00 128.28 C 105.00 128.28 105.00 134.64 120.00 134.64 C 135.00 134.64 135.00 138.64 150.00 138.64 C 165.00 138.64 165.00 140.00 180.00 140.00 C 195.00 140.00 195.00 138.64 210.00 138.64 C 225.00 138.64 225.00 134.64 240.00 134.64 C 255.00 134.64 255.00 128.28 270.00 128.28 C 285.00 128.28 285.00 120.00 300.00 120.00 C 315.00 120.00 315.00 110.35 330.00 110.35 C 345.00 110.35 345.00 100.00 360.00 100.00 C 375.00 100.00 375.00 89.65 390.00 89.65 C 405.00 89.65 405.00 80.00 420.00 80.00 C 435.00 80.00 435.00 71.72 450.00 71.72 C 465.00 71.72 465.00 65.36 480.00 65.36 C 495.00 65.36 495.00 61.36 510.00 61.36 C 525.00 61.36 525.00 60.00 540.00 60.00 C 555.00 60.00 555.00 61.36 570.00 61.36 C 585.00 61.36 585.00 65.36 600.00 65.36 C 615.00 65.36 615.00 71.72 630.00 71.72 C 645.00 71.72 645.00 80.00 660.00 80.00 C 675.00 80.00 675.00 89.65 690.00 89.65 C 705.00 89.65 705.00 100.00 720.00 100.00 C 735.00 100.00 735.00 110.35 750.00 110.35 C 765.00 110.35 765.00 120.00 780.00 120.00 C 795.00 120.00 795.00 128.28 810.00 128.28 C 825.00 128.28 825.00 134.64 840.00 134.64 C 855.00 134.64 855.00 138.64 870.00 138.64 C 885.00 138.64 885.00 140.00 900.00 140.00 C 915.00 140.00 915.00 138.64 930.00 138.64 C 945.00 138.64 945.00 134.64 960.00 134.64 C 975.00 134.64 975.00 128.28 990.00 128.28 C 1005.00 128.28 1005.00 120.00 1020.00 120.00 C 1035.00 120.00 1035.00 110.35 1050.00 110.35 C 1065.00 110.35 1065.00 100.00 1080.00 100.00 C 1095.00 100.00 1095.00 89.65 1110.00 89.65 C 1125.00 89.65 1125.00 80.00 1140.00 80.00 C 1155.00 80.00 1155.00 71.72 1170.00 71.72 C 1185.00 71.72 1185.00 65.36 1200.00 65.36 C 1215.00 65.36 1215.00 61.36 1230.00 61.36 C 1245.00 61.36 1245.00 60.00 1260.00 60.00 C 1275.00 60.00 1275.00 61.36 1290.00 61.36 C 1305.00 61.36 1305.00 65.36 1320.00 65.36 C 1335.00 65.36 1335.00 71.72 1350.00 71.72 C 1365.00 71.72 1365.00 80.00 1380.00 80.00 C 1395.00 80.00 1395.00 89.65 1410.00 89.65 C 1425.00 89.65 1425.00 100.00 1440.00 100.00 L 1440 200 L 0 200 Z" fill="#a78bfa" stroke="none" stroke-width="0" stroke-linecap="round" stroke-linejoin="round" opacity="1">
</path>
</svg>

About this generator

Most CSS wave generators give you a single static SVG — change the color, download the file, ship it. Then the design team asks for parallax, the dev team asks for a React component, the design-system team asks for a Tailwind class, the QA engineer flags the missing aria-hidden, and the EU EAA compliance audit catches the unwrapped infinite animation. This generator was built to fix exactly that gap.

Six wave families — sine, compound, bezier, stepped, organic (feTurbulence), hand-drawn — live in one editor with a family-picker grid. Each family produces a measurably different aesthetic; the Pro tips below tell you when to pick which. Eighteen production templates — SaaS Hero, Footer Wave, Section Transition, Wellness Calm, Agency Bold, E-commerce Banner, Blog Header, 404 Playful, Dashboard Spark, Audio Equalizer, Scrollytelling, Dark Hero, Glassmorphic, Brutalist Sharp, Organic Hand-drawn, Retro 80s Neon, Minimal Mono, Gradient Mesh — give you a starting point that’s already been styled for a specific use case.

Three more differences worth calling out. Multi-layer parallax composer — stack 1-4 waves with independent amplitude, frequency, phase, opacity, and color, then export as either a flat SVG or a CSS-grid stack with scroll-timeline depth offsets. No other generator exports layered SVG. Eight export formats — pure SVG, CSS background-image (data-URL), CSS clip-path (modern shape() + polygon fallback), CSS mask-image (clip images/video into the wave shape), Tailwind arbitrary-value utilities, React + TypeScript, Vue 3 SFC, Svelte, Astro. Zero competitors offer more than two. Responsive triple-preview — render the wave at 360 / 768 / 1440 viewports side-by-side simultaneously to catch breakpoint surprises that single-viewport previews miss.

Permalink: every adjustment encodes into the URL hash, so you can bookmark a tuned wave or send it to a teammate. Hit the ↗ CodePen button to open the wave in a new pen for sharing or blogging. No login, no watermark, no paywall. Free and MIT-licensed.

?

How to use

01
Pick a wave family
Six families up top — Sine (textbook math curve), Compound (sum of harmonics for organic depth), Bezier (smooth fewer-point curve), Stepped (audio equalizer / brutalist), Organic (feTurbulence noise), Drawn (jitter for hand-drawn). Each maps to a different aesthetic; the Pro tips below tell you when to pick which.
02
Start from a real-world template
18 production templates — SaaS Hero, Footer Wave, Section Transition, Wellness Calm, Agency Bold, E-commerce Banner, Blog Header, 404 Playful, Dashboard Spark, Audio Equalizer, Scrollytelling, Dark Hero, Glassmorphic, Brutalist Sharp, Organic Hand-drawn, Retro 80s Neon, Minimal Mono, Gradient Mesh. Click to load, then customize.
03
Tune the geometry
ViewBox width / height set the SVG canvas. Baseline Y is the wave middle. Anchor side picks Top (fills upward), Bottom (fills downward), or Stroke-only (open path, great for sparklines and dashboards). The wave path stays parametric so changes update live.
04
Stack 1–4 layers for parallax depth
Click + Add to stack another wave. Each layer has independent amplitude, frequency, phase, opacity, and color — so you compose depth (low-opacity background wave + mid + foreground). Click L1 / L2 / L3 / L4 to switch which layer the controls edit. No other generator exports layered SVG.
05
Pick fill mode + color
Solid fill or animated linear gradient (from + to). Each layer gets its own color independently — composite gradients are the entire visual identity of SaaS hero sections (Stripe, Linear, Vercel).
06
Animate (optional)
Toggle Animated to add a horizontal drift. Pick Loop (infinite via @property typed angle for smooth GPU interpolation) or Scroll-linked (animation-timeline: scroll() — Chrome 115+, Safari 26+, Firefox flagged). prefers-reduced-motion fallback is automatic. No competitor ships scroll-timeline export.
07
Verify on real backgrounds
Toggle the preview background (Dark / Light / Gray / Card / Brand / Mesh / custom). The contrast badge below shows your first layer color vs the background — WCAG 1.4.11 needs ≥ 3:1 for non-text indicators. Hit the Responsive button to render the wave at 360 / 768 / 1440 simultaneously and catch breakpoint surprises.
08
Export to your stack
Eight formats: SVG (drop-in markup), CSS (background-image data-URL OR clip-path shape()), Mask (mask-image for clipping images/video), Tailwind arbitrary-value class, React + TS, Vue 3 SFC, Svelte, Astro. Output ships aria-hidden="true" + focusable="false" automatically when waves are decorative.
</>

Common wave snippets

SVG (full markup)
<!-- Drop into any HTML — full SVG with multi-layer parallax -->
<svg xmlns="http://www.w3.org/2000/svg"
     viewBox="0 0 1440 200"
     preserveAspectRatio="none"
     width="100%"
     aria-hidden="true" focusable="false">
  <path d="M 0 100 C ... L 1440 200 L 0 200 Z"
        fill="#a78bfa" opacity="1"/>
</svg>
CSS background-image
/* CSS background-image — wave embedded as data-URL */
.hero-wave {
  width: 100%;
  aspect-ratio: 1440 / 200;
  background-image: url("data:image/svg+xml,...");
  background-size: 100% 100%;
  background-repeat: no-repeat;
}
CSS clip-path shape()
/* CSS clip-path: shape() — Chrome 132+, falls back via @supports */
.hero {
  background: linear-gradient(135deg, #6366f1, #a78bfa);
  height: 60vh;
  clip-path: shape(from 0 0, line to 100% 0, line to 100% 80%,
    line to 95% 82%, line to 90% 78%, line to 85% 84%,
    line to 0 82%, line to 0 0);
}

@supports not (clip-path: shape(from 0 0)) {
  .hero {
    clip-path: polygon(0 0, 100% 0, 100% 80%, 95% 82%,
      90% 78%, 85% 84%, 0 82%);
  }
}
CSS mask-image (clip image)
/* CSS mask-image — wave clips an image / video / gradient */
.image-wave {
  width: 100%;
  aspect-ratio: 1440 / 200;
  mask-image: url("data:image/svg+xml,...");
  mask-size: 100% 100%;
  mask-repeat: no-repeat;
  -webkit-mask-image: url("data:image/svg+xml,...");
  -webkit-mask-size: 100% 100%;
  -webkit-mask-repeat: no-repeat;
  background: url("/hero.jpg") center/cover;
  /* The image is now clipped into the wave shape */
}
Animated @property typed-angle
/* @property typed-angle animation — smooth GPU interpolation */
@property --wave-phase {
  syntax: '<angle>';
  initial-value: 0deg;
  inherits: false;
}

.wave-layer-0 { animation: wave-shift 12s linear infinite; }
.wave-layer-1 { animation: wave-shift 14s linear infinite reverse; }
.wave-layer-2 { animation: wave-shift 16s linear infinite; }

@keyframes wave-shift {
  from { transform: translateX(0); }
  to   { transform: translateX(-60px); }
}

@media (prefers-reduced-motion: reduce) {
  .wave-layer-0, .wave-layer-1, .wave-layer-2 { animation: none; }
}
Scroll-linked animation
/* Scroll-linked wave — Chrome 115+, Safari 26+, Firefox flagged */
.wave-layer-0 {
  animation: wave-shift linear;
  animation-timeline: scroll();
}

@keyframes wave-shift {
  from { transform: translateX(0); }
  to   { transform: translateX(-40px); }
}

@supports not (animation-timeline: scroll()) {
  /* Static fallback — wave doesn't animate */
}
Tailwind v3 / v4
<!-- Tailwind arbitrary-value class — works in v3 AND v4 -->
<div class="w-full aspect-[1440/200] bg-no-repeat bg-[length:100%_100%]
            bg-[image:url('data:image/svg+xml,...')]"
     aria-hidden="true" />
React component
// CssWave.tsx — drop-in React component
import React from 'react';

type Props = { className?: string; style?: React.CSSProperties; };

export default function CssWave({ className, style }: Props) {
  return (
    <div
      className={className}
      style={{ width: '100%', aspectRatio: '1440 / 200', ...style }}
      aria-hidden="true"
      dangerouslySetInnerHTML={{
        __html: `<svg ...>...</svg>`
      }}
    />
  );
}

Browser support

Every output the generator emits — SVG paths, CSS background-image data-URLs, mask-image, @property typed angles, prefers-reduced-motion — is supported in every evergreen browser. clip-path: shape() needs Chrome 132+ (falls back to polygon via @supports). animation-timeline: scroll() needs Chrome 115+ / Safari 26+ (falls back to static via @supports). feTurbulence (Organic family) is universally supported. Safe to ship anywhere.

Chromev85+
Safariv16+
Firefoxv128+
Edgev85+

Pro tips

01
Sine vs Compound vs Bezier — pick by aesthetic
<strong>Sine</strong> is the textbook math wave — predictable, symmetrical, great for minimalist designs (Minimal Mono preset). <strong>Compound</strong> is sum-of-harmonics — adds visual depth without looking artificial, the go-to for modern SaaS hero sections (Stripe, Linear). <strong>Bezier</strong> uses fewer control points so the curve reads smoother and lighter — perfect for sparklines and dashboard charts. Pick the simplest family that meets the design — extra mathematical complexity has zero aesthetic payoff.
02
Multi-layer parallax — the SaaS hero recipe
Three waves stacked is the canonical SaaS hero pattern (Stripe, Linear, Vercel, Notion). Recipe: <strong>Background layer</strong> — large amplitude (40-60px), low opacity (0.3-0.4), longer wavelength. <strong>Mid layer</strong> — medium amplitude, 0.5-0.7 opacity, shifted phase (90°). <strong>Foreground</strong> — smaller amplitude (24-36px), full opacity, shifted phase (180°). Each layer drifts at a different speed in scroll-linked mode → real parallax depth at zero JS cost. Load the SaaS Hero preset for a ready-made example.
03
Clip-path shape() vs SVG vs mask-image — three different exports for three different needs
<strong>SVG path</strong> — best for layered, animated, or filtered waves. Embeds the wave as <code>&lt;path&gt;</code> elements you can target individually. <strong>CSS clip-path: shape()</strong> — best when you want the wave to clip an element (a section, a div) without an extra SVG file. Modern Chrome 132+; falls back to <code>polygon()</code> approximation elsewhere. <strong>CSS mask-image</strong> — best when you want to clip an IMAGE or VIDEO into the wave shape. Pass any image / gradient / video as the background; the wave becomes a window. No competitor handles all three — most do SVG only.
04
Animate phase + transform, never the d attribute
Older tutorials show animating the <code>d</code> attribute via <code>@keyframes</code> string interpolation — this is jank-prone and breaks on path-length mismatches. The modern approach: register <code>--wave-phase</code> as <code>&lt;angle&gt;</code> via <code>@property</code> and animate via <code>transform: translateX()</code> on each layer. Smooth GPU compositing, no path recomputation. The generator emits this automatically.
05
Mark decorative waves aria-hidden
A wave divider conveys visual hierarchy, not information. Screen readers should skip it. The generator auto-adds <code>aria-hidden="true"</code> + <code>focusable="false"</code> on the &lt;svg&gt;. Without these, NVDA / JAWS / VoiceOver announce "graphic, graphic, graphic" between every section — exhausting for blind users. The exception: a wave that DOES carry meaning (e.g. audio waveform in a player) needs <code>role="img"</code> + <code>aria-label="Audio waveform"</code>.
06
Watch SVG byte size for hero waves
A wave SVG over ~2KB compressed is a Core Web Vitals warning — base64-encoded into a <code>background-image: url(data:image/svg+xml,...)</code> the encoding adds ~35% byte overhead. The performance badge below the preview shows your current SVG size. Strategies: fewer control points (Bezier family does this naturally), simpler paths (skip turbulence unless visually necessary), prefer inline SVG over data-URL backgrounds for hero waves, lazy-load below-fold decorative waves with <code>loading="lazy"</code> on the wrapping <code>&lt;img&gt;</code>.
?

Frequently asked questions

01

Why does this generator have 6 wave families when most have only 1?

Because each family produces a measurably different aesthetic and the wrong one looks generic. Sine is the textbook math curve — symmetrical, predictable, the default for minimalist and editorial designs. Compound is the sum of two harmonics (primary + half-amplitude double-frequency overtone) — adds organic depth without looking artificial, the canonical pattern for SaaS hero sections (Stripe, Linear, Vercel, Notion). Bezier uses fewer control points and smooth cubic interpolation — renders lighter (smaller SVG byte size), reads as a single continuous gesture, perfect for sparklines and dashboard chart elements. Stepped jumps between discrete Y values — audio equalizer aesthetic, brutalist designs, retro pixel-art. Organic applies an SVG <feTurbulence> filter to add fractal noise displacement — hand-rendered or watercolor feel. Drawn adds deterministic per-point jitter — looks hand-drawn / sketched / imperfect, the rough-and-friendly aesthetic of Excalidraw, RoughJS, or hand-illustrated marketing sites. Competitors like Haikei ship multiple visual styles but lock them behind discrete preset libraries; getwaves.io / shapedivider give you a sine + nothing else. This generator gives you all six in one editor with live parameter customization on every family.

02

Multi-layer parallax waves — when and how to use them?

Three to four layered waves is the canonical SaaS hero pattern (Stripe homepage, Linear marketing, Vercel landing, Notion product pages). The recipe: Background layer — large amplitude (40-60px), low opacity (0.25-0.4), longer wavelength (1-1.5 cycles). Mid layer — medium amplitude (35-45px), 0.5-0.7 opacity, phase shifted 60-90° from the background. Foreground layer — smaller amplitude (24-36px), full opacity, phase shifted 180° from background. Each layer drifts at a different speed in scroll-linked mode (the further back, the slower) — producing real parallax depth at zero JavaScript cost. The illusion sells because human depth perception keys on relative motion speed; a stationary distant wave with a faster-moving foreground reads as 3D. Performance note: each layer adds path complexity but no DOM cost (single SVG with multiple paths), and modern browsers composite SVG paths on the GPU at 120fps on M-series Macs and ProMotion displays. When NOT to layer: footer dividers, section transitions, single-purpose sparklines — one layer is enough. Layering is for hero sections where the wave IS the visual identity. The 18 templates ship with sensible layer counts per use case.

03

Clip-path vs SVG vs mask-image — which wave technique do I pick?

Three different exports for three different needs. 1. SVG path (best for layered, animated, or filtered waves) — embed the wave as an inline <svg> with individual <path> elements. Lets you target each layer for separate animations, opacity changes, or transforms. The default and most flexible export. 2. CSS clip-path: shape() (best when you want the wave to clip an HTML element without an extra SVG file) — modern Chrome 132+ with polygon() fallback via @supports in older browsers. The wave shape becomes the boundary of a div, section, or hero — content above the wave appears, content below gets clipped. Single CSS property, no extra HTML. 3. CSS mask-image (best when you want to clip an IMAGE, VIDEO, or GRADIENT into the wave shape) — pass any background through the mask: a photo becomes a wave-shaped photo, a video becomes a wave-shaped video, a gradient becomes a wave-shaped gradient. The element retains its original content but only the wave-shaped region is visible. Decision rule: animated or layered → SVG. Single clip on a div → clip-path. Clip an image / video / gradient → mask-image. The generator emits all three from the same parametric wave definition; no competitor offers more than one.

04

How do I animate the wave smoothly without jank? (@property typed-angle + linear() easing)

Older tutorials show animating the SVG d attribute via @keyframes string interpolation — this is jank-prone (the browser has to re-tessellate the path on every frame) and breaks completely on path-length mismatches. The modern 2026 approach: register a custom CSS property --wave-phase as <angle> via @property, then animate transform: translateX() on each layer. This composites on the GPU compositor thread — no main-thread layout, no path recomputation, smooth at 120Hz on ProMotion / VRR displays. Easing: pair the typed angle with linear(...) (Chrome 113+, Safari 17.2+, Firefox 112+) for custom progress curves — particularly useful for slow ambient waves (10s+ duration) where cubic-bezier can look judderry on variable-refresh-rate screens. Browser support: @property works in Chrome 85+, Safari 16+, Firefox 128+; falls back to a step-change in older browsers via @supports. The generator emits the entire animation block with the reduced-motion guard automatically.

05

How does scroll-timeline wave animation work? Browser support?

animation-timeline: scroll() is the 2024 CSS feature that lets an animation's progress be driven by scroll position instead of wall-clock time. Set up: .wave-layer { animation: wave-shift linear; animation-timeline: scroll(); } — the wave's translateX now interpolates from 0 to its end-state value as the user scrolls from 0% to 100% of the document. The browser handles all the interpolation on the GPU compositor — no scroll-listener JavaScript, no requestAnimationFrame, no jank. Browser support: Chrome 115+ (June 2023), Edge 115+, Safari 26+ (in development as of 2026), Firefox flagged behind layout.css.scroll-driven-animations.enabled. Fallback strategy: wrap the animation in @supports (animation-timeline: scroll()) — browsers that don't support it skip the animation entirely (wave stays in its base state, still looks fine, just doesn't drift on scroll). The generator emits the @supports guard automatically. Real-world adoption: this is THE 2025-2026 modern web pattern — Vercel, Linear, Apple, and most Awwwards Site of the Year recipients use it. Zero competitors export scroll-timeline waves; you'd have to hand-write it. Our Scrollytelling preset gives you a ready-made example.

06

Will the Tailwind export work with Tailwind v3 AND v4?

Yes. The generator emits Tailwind arbitrary-value utilities (square-bracket syntax like w-full aspect-[1440/200] bg-no-repeat bg-[length:100%_100%] bg-[image:url('data:image/svg+xml,...')]) which both Tailwind v3 and v4 consume identically — no migration needed. The data-URL SVG is properly URL-encoded to survive the CSS attribute value escape rules in both Tailwind versions. For frameworks that ship with shadcn/ui, Aceternity UI, or Magic UI, the React export is a drop-in CssWave.tsx component with TypeScript props; the SVG is inlined so there's no extra network request. The mask-image export works with both Framer Motion (for animated mask transitions) and plain CSS transitions. No external dependencies, no required npm packages.

07

How is the wave accessible? aria-hidden, contrast, prefers-reduced-motion

Three a11y guardrails baked into every export. 1. aria-hidden="true" + focusable="false" on the <svg> when the wave is decorative (the default). Without these, screen readers (NVDA / JAWS / VoiceOver / TalkBack) announce "graphic" between every page section — exhausting for blind users and prohibited by WCAG 1.1.1 (Non-text Content) when the graphic conveys no information. The generator's Accessibility panel lets you uncheck this for waves that DO carry meaning (audio waveforms, data visualizations) — in which case you should also add role="img" + aria-label="Audio waveform showing peaks at 0:32 and 1:14". 2. Live WCAG 1.4.11 (Non-text Contrast) check — the contrast badge below the preview shows your first layer color vs your chosen background; non-text indicators need ≥ 3:1 contrast or they're invisible to users with low vision. Pale-gray wave on slightly-darker-gray background is the most common a11y bug in 2026 hero sections. 3. prefers-reduced-motion: reduce media query wrapping every animated wave. ~35% of adults have some level of motion sensitivity (vestibular disorders, migraine triggers, ADHD visual-processing, PTSD photosensitivity). Continuous wave drift on a hero section can trigger nausea or vertigo. The generator's reduced-motion guard stops the animation but keeps the wave visible. Regulatory frameworks: WCAG 2.2, EU EAA (June 2025 enforcement), US Section 508, Canada ACA, UK Equality Act 2010, Australian DDA all require WCAG 2.2 AA compliance — decorative SVGs that don't aria-hidden are routine audit failures.

08

How does this compare to Haikei, getwaves.io, shapedivider, sssurf?

Haikei: the most polished designer-tool — multiple generator types (waves, blobs, peaks, layered), beautiful presets, share URLs. But: no animation export, no framework snippets, no a11y, exports flat SVG only (no individual layer access for parallax). Designer-first, dev-second. getwaves.io: cleanest single-wave UX, 5 preset styles, color picker, SVG download. But: no animation, no multi-layer, no CSS/React export, no clip-path output, no responsive preview. shapedivider.app: HTML + SVG snippet output, top/bottom flip, mobile/tablet/desktop heights. But: "premade shapes not dynamic to settings" — no true parametric control over amplitude/frequency/phase, no animation, no layering, no framework export. fffuel sssurf: multi-undulation amplitude/spacing control, beautiful SVG download. But: no animation, no CSS clip-path, no framework export. svgwave.in: gradient + transparency presets, SVG download. Single layer only, no animation, no CSS-only output. wavegenerator.app: pure CSS clip-path waves, no SVG. Single shape, no animation, no responsive preview. This generator vs all of the above: 6 wave families (most competitors ship 1-2), multi-layer parallax composer (Haikei stacks visually but exports flat SVG), 8 export formats including SVG + CSS background + clip-path + mask-image + Tailwind + React + Vue + Svelte + Astro (zero competitors offer more than 2), @property typed-angle animation, scroll-timeline export (nobody else ships this), responsive triple-preview at 360 / 768 / 1440 simultaneously (every competitor previews on a single viewport), live WCAG contrast check, auto aria-hidden, 18 real-world production templates (SaaS hero, footer, divider, 404, sparkline, equalizer, scrollytelling, dark hero, glassmorphic, brutalist, organic, retro neon, minimal, gradient mesh). MIT licensed, no login, no watermark.

09

How do I prevent CLS (Cumulative Layout Shift) when the wave loads?

Cumulative Layout Shift is one of three Core Web Vitals Google measures on every Lighthouse / PageSpeed Insights audit. A wave that pops in late shifts content below it and spikes your CLS score. Two strategies baked into the generator output. 1. aspect-ratio reservation — every export wraps the wave in a container with aspect-ratio: 1440 / 200 (your chosen viewBox dimensions) so the layout reserves vertical space BEFORE the SVG paints. Even if the SVG is slow to fetch or render, the surrounding layout doesn't shift. 2. Inline SVG over data-URL for above-the-fold waves — the SVG export embeds the wave as inline markup that ships in the initial HTML response, so it renders on first paint with zero network round-trip. Data-URL background images are slightly more compact but trigger a separate CSS parse + decode that can shift layout if the wave is large. Measurement: use PageSpeed Insights, Chrome DevTools Performance Insights (Layout Shift detail), WebPageTest, or the Core Web Vitals report in Google Search Console. For below-the-fold decorative waves, add loading="lazy" to any wrapping <img> tag to defer the fetch entirely.

10

Why is the URL changing as I drag sliders? And what's the CodePen button?

Every adjustment (amplitude, frequency, phase, layer count, color, animation) is encoded into the URL hash (the part after #) so the entire wave config is shareable. Bookmark a tuned wave, reopen the URL, the wave is exactly where you left it. Send the URL to a colleague or paste it in a design-system doc — they see your exact configuration, with every slider in the right position. No accounts, no servers, no logins required. The hash is base64-encoded JSON; inspect it in DevTools if you're curious. This is especially useful for design-system documentation pages — link to the canonical wave URL from your style guide and the live editor opens with your wave preloaded for the next designer to fork. CodePen button: hit "↗ CodePen" next to the stats bar to open a new pen pre-populated with your wave's SVG markup. Great for sharing on social, embedding in blog posts, or showing variants. The button uses CodePen's /pen/define POST endpoint — no API key, no signup, opens directly in CodePen's editor. Combined with our CSS Loaders collection, CSS Banners, and our other generators (CSS Gradient generator, CSS Clip-path generator, CSS to Tailwind converter) you have a full hero-section toolkit.

Search CodeFronts

Loading…