Code examples and resources for AudioWorklet.

Basic Demo

Hello Audio Worklet!

Bypassing input to output

One Pole Filter

One-pole filter built with Audio Worklet

Noise Generator with AudioParam

Noise generator with user-defined AudioParam

BitCrusher with AudioParam

Declative AudioParam configuration and its automation


Messaging between an AudioWorkletNode and the associated AudioWorkletProcessor

Volume Meter

Measures microphone volume with AudioWorkletProcessor

AudioWorkletNode Options

Passing AudioWorkletNodeOptions from the node to the associated AudioWorkletProcessor

Handling Errors

How to handle errors from AudioWorkletProcessor

Advanced Design Pattern

Audio Worklet and WebAssembly

A basic set up for AudioWorklet and WebAssembly

WebAssembly Supersaw

C++ Supersaw synth to WebAssembly (Google I/O 2019, Audio Developer Conference 2021)

Ring Buffer in AudioWorkletProcessor

Using Ring Buffer to work around buffer size mismatch

Audio Worklet, SharedArrayBuffer, and Worker

For high performance large-scale audio applications


Simple Passthrough

Basic example of FreeQueue and a worker thread. FreeQueue is a lock-free ring buffer library for high-performance audio processing designed to be used on top of the Web Audio API. This example demonstrates how this library can be used as a channel between a worker thread and AudioWorklet to send audio data.

Migration from ScriptProcessorNode

ScriptProcessorNode Recorder

A simple audio recording app using ScriptProcessorNode

AudioWorklet Recorder

A simple audio recording app using AudioWorklet


Enter AudioWorklet

An introductory article on Audio Worklet

AudioWorklet Design Pattern

Design with WebAssembly SharedArrayBuffer and more

AudioWorklet - The future of web audio

The first conference paper about AudioWorklet (ICMC 2018)