Feature Library

Synthesised UI sounds

<0.01 CPU ms
A still of the Synthesised UI sounds demo
Still
The live demo starts when it’s in view.Click once to start audio, then use the controls or the pads · the scope draws each sound, even when muted

Twelve interface sounds made live with the Web Audio API, no audio files.

What it costs a frame

<0.01 ms
GPU
not used
CPU, median
<0.01 ms
CPU, 95th pct
<0.01 ms
Draw calls
0
Weight
Light

Measured 3 November 2026 on 13th Gen Intel(R) Core(TM) i9-13900H, Chrome 156, 1920×1080 at 1×. 600 frames × 3 rounds, median kept. What ran: Measured idle: the bench run has no user gesture, and headless Chrome as the bench launches it keeps an AudioContext suspended without one (checked), so no sound can play. The cost of a sound is a few short-lived Web Audio nodes; the mixing runs on the browser’s audio thread, outside the frame. Phones: tiers are being measured next.

On every machine it was measured on
MachineGPU msCPU msCPU p95
unknown GPU · 13th Gen Intel(R) Core(TM) i9-13900Hreference · measuring toolnot timed<0.01<0.01
apple · Apple A19 Proin a browser tab · 16 November 2026not timed<0.01<0.01
Intel Arc 140V (Xe2-LPG) · Intel Core Ultra 7 258Vin a browser tab · 15 November 2026not timed<0.010.01

Bars against one 16.7 ms frame. A browser-tab run is timed in a visible tab without the tool’s scripted input, so read it as close, not exact.

What it needs

Renders with
DOM and CSSPlain DOM and CSS: every current browser.
Your browser
Runs hereNo WebGPU needed
Depends on
NothingNo other packages

What it’s for

  1. Buttons, switches and sliders that feel physical
  2. Save, success and error feedback
  3. Notifications and chat
  4. Games and playful tools
  5. Kiosks and touch screens
  6. Dashboards that need a quiet alert

Pitfalls, in brief

  1. Browsers keep an AudioContext suspended until the page has had a click, a tap or a key press.
  2. On touch, pointerdown does not count as a gesture: the module also listens to pointerup, touchend and click, so the first tap starts audio, but the very first press sound of that tap is lost.
  3. UI sounds are an extra, never the only feedback: anything a sound says (it saved, it failed, a message arrived) must also show on screen, for people who are deaf or have sound off.
  4. Sounds should be opt-in in most apps: give the app a "Sounds" setting that starts off (or on only where sound is expected, such as games) and pass it as enabled.
  5. Reduced motion does not mute the sounds: it is a preference about movement, and people who reduce motion may rely more on sound.
3 more in brief
  1. Keep them short and quiet: under 100 ms for controls, under 1 s for anything, and well below other media.
  2. Each play builds a few Web Audio nodes; they are freed when they finish.
  3. stop() closes the AudioContext: browsers limit how many a page may have, so make one system per app, not one per component.
8 pitfalls in full, the hook-up guide, the module source and its tests come with the part.

Where it comes from

From HaTac. Fully custom code.

web audiosound designfeedbacksynthesisaccessibilityreduced motiondomno dependencies

Near it in the frame