New — hover-time tooltips & auto-highlighting markers in WaveformPlayer 1.16. What's new →
v1.19.1 Now with full data-attribute coverage

Beautiful audio visualization, no JavaScript required.

A small, zero-dependency family for the web — a canvas waveform player, a persistent bottom bar, playlists, analytics and build-time tooling. Add a few data attributes and ship.

$ npm i @arraypress/waveform-player

Pick your package manager — or hand it to your agent.

~10KB gzipped · Zero dependencies · 6 visual styles · MIT licensed

121.6k downloads/mo 17 packages

Zero config

Drop in a <div>. That's the whole setup.

No bundler, no framework, no init call. Include the script, add attributes, and every matching element becomes a player on load.

index.html
<link rel="stylesheet"
  href="https://unpkg.com/@arraypress/waveform-player/dist/waveform-player.css">
<script src="https://unpkg.com/@arraypress/waveform-player"></script>

<div data-waveform-player
     data-url="track.mp3"
     data-artwork="cover.webp"
     data-title="Midnight Dreams"
     data-artist="The Wavelength"
     data-waveform-style="mirror"
     data-show-bpm="true"
     data-bpm="120"></div>

Six visual styles

One attribute switches the look.

bars · mirror · line · blocks · dots · seekbar — every style reads the same waveform data and adapts to your theme.

Bars data-waveform-style="bars"
Mirror data-waveform-style="mirror"
Line data-waveform-style="line"
Blocks data-waveform-style="blocks"
Dots data-waveform-style="dots"
Seekbar data-waveform-style="seekbar"

New in v1.10

A compact layout for sample packs.

The preview layout centers the title under the waveform and trims the controls — drop a grid of them into any sample or beat store.

Built for the modern web

Everything you need, nothing you don't.

Zero JavaScript

Add a few data attributes to any element. Auto-initializes on load — no build step, no wiring.

~10KB gzipped

The whole core, zero dependencies. Canvas rendering, controls and keyboard support included.

Media Session

Lock-screen artwork and hardware media keys via the Media Session API, out of the box.

Keyboard ready

Space, arrows, number keys and an accessible seek slider — fully operable without a mouse.

Playback speed

Per-player speed control with configurable rates — built for podcasts and courses.

Auto theme

Detects the surrounding background and adapts its palette. Dark, light, or anything between.

The family

One core. A whole audio toolkit.

The player is the foundation — extensions snap on to cover real-world products: a persistent bar, playlists, analytics, and a peaks generator.

WaveformBar v1.9.0

A persistent, Spotify-style bottom bar.

Queue, volume, repeat, favorites, cart and DJ markers — with cross-page session persistence. Pick a track to launch the real bar.

  • Play queue
  • Favorites & cart
  • Repeat modes
  • Session persistence
Explore the bar
WaveformPlaylist v1.7.0

Playlists and chapters, from markup.

Turn a list of tracks into a full album or podcast player with artwork, durations and chapter navigation — keyboard-accessible out of the box.

  • Track list + artwork
  • Chapter markers
  • Continuous play
  • N / P / 1–9 keys

Album

Podcast series · tracks + chapters

Introduction
The main idea
Going deeper
Wrap-up
Cold open
The interview
Sign-off
WaveformTracker v1.0.1

Know what's actually heard.

Privacy-first engagement analytics — credits real media-time, ignores seeks, no cookies. Send to any endpoint or handler.

Listens · last 7 days 18%
12,480
WaveformGen v1.5.1

Pre-compute peaks at build time.

A tiny Node CLI that turns audio into peak JSON (and BPM) so players paint instantly — no client-side Web Audio decode.

Generating peaks… 1800 samples

Framework wrappers

Typed components for Astro, React, Vue, and Svelte.

The same player, the ergonomics you expect — every option as a typed prop, SSR-safe, with the core left untouched.

Player.astro
---
import WaveformPlayer from '@arraypress/waveform-player-astro';
---
<WaveformPlayer
  src="/track.mp3"
  title="Midnight Dreams"
  waveformStyle="mirror"
  showBPM
/>
Track.tsx
import { WaveformPlayer } from '@arraypress/waveform-player-react';

export function Track() {
  return (
    <WaveformPlayer
      url="/track.mp3"
      title="Midnight Dreams"
      waveformStyle="mirror"
      showBPM
    />
  );
}

17 packages

The whole family, on npm.

Mix and match — install only what you need. Every package is public, MIT-licensed and dependency-light.

v1.19.1

WaveformPlayer~10KB

The zero-config core. Canvas waveform player with six visual styles, keyboard control and Media Session — vanilla JS, zero dependencies.

Core
v1.9.0

WaveformBar~6KB

Persistent Spotify-style bottom bar — queue, volume, repeat, favorites, cart, DJ markers and cross-page session persistence.

Extension
v1.7.0

WaveformPlaylist~4KB

Playlist and chapter navigation — podcasts, courses, albums and audiobooks. Fully keyboard-accessible.

Extension
v1.0.1

WaveformTracker~2KB

Privacy-first listen analytics. Credits real media-time engagement, ignores seeks, no cookies — send to any endpoint.

Extension
v1.5.1

WaveformGen

Node CLI + library to pre-generate waveform peaks (and BPM) from audio files — instant render, no client-side decode.

Tooling
v0.4.0

Player · Astro

Typed Astro component wrapper with lazy IntersectionObserver mounting.

Framework
v0.4.0

Player · React

React wrapper — forwardRef imperative handle and typed props.

Framework
v0.2.0

Bar · Astro

<WaveformBar> + <WaveformBarTrigger> components for Astro.

Framework
v0.2.0

Bar · React

<WaveformBar> + <WaveformBarTrigger> components for React.

Framework
v0.2.1

Playlist · Astro

Typed <WaveformPlaylist> for Astro — tracks and chapters as props.

Framework
v0.2.0

Playlist · React

React <WaveformPlaylist> — typed tracks/chapters and a ref handle.

Framework
v0.2.0

Player · Vue

Vue 3 wrapper — typed props, event emits and a template-ref imperative handle.

Framework
v0.2.0

Player · Svelte

Svelte 5 wrapper — typed props, callback props and exported instance methods.

Framework
v0.1.0

Bar · Vue

<WaveformBar> + <WaveformBarTrigger> components for Vue 3.

Framework
v0.1.0

Bar · Svelte

<WaveformBar> + <WaveformBarTrigger> components for Svelte 5.

Framework
v0.2.0

Playlist · Vue

Vue 3 <WaveformPlaylist> — declarative tracks/chapters and a ref handle.

Framework
v0.2.0

Playlist · Svelte

Svelte 5 <WaveformPlaylist> — declarative tracks/chapters and exported nav methods.

Framework

Use cases in 2026

What people build with it in 2026.

From sample packs and beat stores to podcasts, audiobooks and AI voice — a lightweight waveform audio player that drops into any product with a script and a <div>. Accessible, keyboard-first and MIT-licensed.

Sample & loop stores

Preview sample packs, loops and one-shots on Shopify, WooCommerce or any storefront — pre-computed peaks paint the waveform instantly, no decode.

Beat marketplaces

Sell beats and type beats with a persistent play bar, queue and add-to-cart triggers — straight from markup, no framework required.

Podcasts

Ship podcast episode players with chapters, variable playback speed and Media Session lock-screen controls out of the box.

Audiobooks

Long-form audiobook and chaptered narration players with resumable position and keyboard-first seeking.

AI voice & TTS

Showcase AI voiceovers, text-to-speech and voice-cloning demos with a clean waveform and instant scrubbing.

Courses & e-learning

Audio lessons, language practice and lecture recordings with chapters and full keyboard control — accessible to every learner.

Musicians & labels

Embed releases, EPs and demos as album playlists with per-track artwork and BPM — from plain HTML.

DJ mixes & radio

Continuous DJ mixes and radio shows with cue markers, gapless queue advance and cross-page playback persistence.

Sound effects & SFX

Browse sound-effect and foley libraries where the waveform shape is the fastest way to find the right hit.

Meditation & wellness

Sleep sounds, ambient tracks and guided-meditation apps with a calm, monochrome player that matches any theme.

Publishers & news

Listen-to-this-article audio and AI voice summaries that adapt to light or dark page themes automatically.

Voice notes & social

Voice messages, audio comments and UGC waveforms in social and messaging apps — tiny footprint, framework-agnostic.

How it compares

A toolkit, not just a waveform.

WaveformPlayer WaveSurfer.js Amplitude.js
Zero-config HTML
Canvas waveform
Six visual styles
Media Session API
Persistent bottom bar
Playlist + chapters
Listen analytics
Accessibility + keyboard
Framework wrappers
Zero dependencies

Capability comparison; each library has its own strengths.

Framework agnostic

Works anywhere a <script> does.

HTML
React
Vue
Svelte
Astro
WordPress
Shopify

Start shipping beautiful audio.

Free, open-source and ~10KB — add a div and go.

Read the docs

API reference, guides and recipes for all nine packages.

Browse docs

Open the builder

Configure a player visually and copy the HTML, JS or React.

Try it

Star on GitHub

MIT-licensed, open source, zero dependencies.

View source