Why
What a session recorder should not doThe recorder freezes the page it records.
The page is read at rest, at most every 50 ms. 3.6× shorter start than rrweb.MeasuredA 23.6 KB script for a feature visitors never see.
7.8 KB gzip, recording and sending included.MeasuredEvery visitor uploads the same stylesheets again.
What the server already holds goes as a hash.BuiltPasswords and card numbers end up on your servers.
Masked in the core, before any module. Always.BuiltA chunk gets lost and the replay quietly lies.
The hole is marked. Play resumes at the next snapshot.BuiltSeeking back replays the whole session.
A checkpoint every 10 s. Seeks start from the nearest.BuiltThe replay runs the site's scripts.
Rebuilt through the DOM API, in a sandbox, without scripts.BuiltOne broken plugin kills the recording.
A module that throws is cut alone. The rest goes on.BuiltLighter
Same pages, same masking, same browsershorter freeze than rrweb when recording starts, on lemonde.fr.
How
Three callsA snapshot, then what changed. Typed values stay on the page.
Chunks to your endpoint. A beacon on the way out.
A sandboxed copy, rebuilt node by node. Seek anywhere.
// bun add @voila.dev/replay
import { record } from "@voila.dev/replay/record";
import { connect } from "@voila.dev/replay/send";
const rec = record(window, { mask: "inputs" });
const link = connect({ endpoint: "/replay", head });
link.send(rec.snap());
setInterval(() => link.send(rec.drain()), 5000);
addEventListener("pagehide", () => link.leave(rec.drain()));// later, wherever you watch import { createPlayer } from "@voila.dev/replay/play"; const player = createPlayer({ root, chunks }); player.play(); player.seek(42_000); // from the nearest checkpoint
Demos
Live, in your browserYour page on the left, its copy on the right, the tape in between.
Type a card number. The copy only gets stars.
Lose a chunk on purpose. The player says so.
Scrub back through the session, from checkpoints.
Recording sessions with rrweb? Tell us what it costs you.