Media Session Playground - Interactive Web API Lab | IconVault

Master the Media Session API: build metadata, set playback state and wire action handlers that respond to real media keys. Free, in your browser.

All tools

Media Session Playground

Metadata builder, playback state and real media key handlers

5 of 5 free uses left
navigator.mediaSession is not available here. The builder still generates the exact code; run it in Chrome/Edge to see OS controls light up.

playbackState

Action handlers

5 of 5 free publishes left.

Now-playing card (what your OS sees)

Artwork

Neon Horizons

IconVault Studio - Web Audio Demos

playbackState: none

Media keys / lock-screen buttons route to your handlers

Action handler log

Publish metadata, play the test tone, then press your keyboard media keys or lock-screen controls to see the handlers fire.

About this tool

IconVault's Media Session Playground drives the real `navigator.mediaSession` API: build metadata (title, artist, album, artwork), flip the playback state between playing and paused, and register action handlers for play, pause, next track and previous track that respond to your keyboard's actual media keys, headset buttons and OS media controls. It is free and runs fully in your browser.

You will learn why every audio and video app should set media metadata: it powers the lock-screen player, notification controls and picture-in-picture overlays on phones and desktops. The lab shows which artwork sizes each platform prefers, how `setPositionState()` keeps scrubbers in sync, and the graceful pattern for handlers the browser does not support: check first, register only what exists.

Frequently asked questions

Popular searches

media session apinavigator.mediasessionmedia session javascriptmedia metadata apimedia keys webheadset buttons weblock screen media controlsweb audio metadatanow playing webMediaMetadatasetactionhandlermedia session actionsplay pause handlerprevioustrack nexttrackseekbackward seekforwardsetpositionstateplaybackstate media sessionmedia session artworkmedia session examplemedia session tutorialmedia session demomedia session playgroundmdn media sessionmedia session chromemedia session safarimedia session androidmedia controls web apppodcast web player controlsmusic player web apipicture in picture metadatanotification media controlsos media overlayhardware media keys javascripthow to add media keys to websiteweb player lock screenaudio player metadatavideo player metadatamedia session typescriptcaniuse media sessionis media session supportedmedia session eventsmedia session seektomedia session stop actionweb media player apibluetooth headset webmedia notification webmedia artwork sizesalbum art web playermedia session position slidermedia session demo onlineweb audio session api

More tools

Coming soon

CLI

Coming soon

Figma plugin

Coming soon

VS Code extension

Coming soon

Chrome extension

Coming soon

AI icon generator

Coming soon

Team workspaces

Coming soon

View all 10+ tools →