ChatViz
A private, client-side viewer for your Instagram, Snapchat and WhatsApp chat exports. Your conversation archives are processed entirely in browser memory and saved into an encrypted local vault—no servers, no telemetry, no tracking.

Multi-Platform Import
Parses Instagram message_*.json with automated Mojibake UTF-8
repair, Snapchat chat_history.json, and raw WhatsApp
.txt or media-packed .zip exports.
Zero-Trust Network Air Gap
Enforces a strict Content-Security-Policy with
connect-src ‘none’ and frame-ancestors ‘none’. The
application cannot execute outbound fetches, XHRs, WebSockets, or analytics
beacons.
Encrypted In-Browser Vault
Protects stored chats using PBKDF2-SHA256 (600,000 iterations) and AES-256-GCM. Decryption keys exist exclusively in volatile memory and are purged on tab close or manual lock.
High-Capacity Virtualization
Powered by @tanstack/react-virtual to smoothly render over
100,000 messages with dynamic height estimation, date separators, and sticky
headers at 60 fps.
Streaming Zip64 Engine
A custom random-access unzipper reads media directly from multi-gigabyte ZIP archives on demand using file slice handles without buffering entire archives in browser RAM.
Accessible Theme Engine
Five background themes (Dark, AMOLED for OLED screens, Midnight, Mocha, Light) and seven accent shades verified for WCAG AA contrast (4.5:1) across every surface.
Overview
When you request your data archives from messaging services like Instagram, Snapchat, or WhatsApp, you receive gigabytes of raw JSON files, fragmented text logs, and nested media folders. Existing viewer tools require uploading these sensitive conversations to remote third-party servers.
ChatViz solves this without compromising privacy. All parsing, unzipping, decrypting, and rendering executes 100% on the client. Outbound network communication is blocked at the browser level through a strict Content Security Policy.
Supported Export Formats
1. Instagram (message_*.json)
- Mojibake UTF-8 Repair: Resolves Instagram’s longstanding export bug where Unicode text (emojis, accented characters) is encoded as broken Latin-1 byte escapes (e.g.
\u00c3\u00a9decoded to clean characters). - Multi-File Thread Stitching: Automatically merges split sequential files (
message_1.json,message_2.json) into single chronological conversation threads. - Inline Reactions: Renders Instagram reaction notifications as compact interactive emoji pills overlaid on the target message bubble.
2. Snapchat (chat_history.json)
- Ingests the full conversation tree rather than just the single largest thread.
- Maps ephemeral media notices, text messages, and timestamped shared stories.
3. WhatsApp (.txt and .zip)
- Zip64 Random-Access Reader: Opens multi-gigabyte WhatsApp
.ziparchives directly using range slices from the localFilehandle, streaming photos, videos, voice notes, and stickers on demand without exhausting device memory. - Universal Date & Time Parsing: Automatically identifies 12-hour/24-hour clocks and ambiguous month/day ordering based on entire log context.
Interface & Aesthetics
The interface is inspired by classic message bubbles and doodle aesthetics, featuring rounded corners, subtle transitions, and hand-drawn accents.




Client-Side Pipeline Architecture
Dataflow & Cryptographic Architecture
connect-src 'none' (Zero Outbound Requests)Export Archives
message_*.json split logs, thread stitching & reaction maps
chat_history.json full conversation tree and shared story media
Raw text logs + media-packed archives with dynamic 12h/24h timestamp detection
Web Worker
Offloads 100% of archive parsing and JSON decoding off the main UI thread
Reads media slices directly from the File handle on demand without full RAM copies
Corrects broken Instagram Latin-1 byte escapes into native Unicode emojis and accents
WebCrypto Vault
600,000 iterations stretch user passphrase with a cryptographically random 16-byte salt
Authenticated symmetric encryption for conversation messages, metadata, and media blobs
IndexedDB store keys and participant hashes are blinded against physical storage analysis
Virtual UI & Storage
Multi-gigabyte persistence across sessions; master decryption key lives only in volatile RAM
Smoothly virtualizes 100,000+ messages at 60 fps with dynamic height estimation & sticky dates
Five contrast-checked themes (Dark, AMOLED, Midnight, Mocha, Light) and seven accent shades
- Dedicated Web Worker: File parsing and unzipping run off the main thread inside an inline
blob:worker. Heavy multi-megabyte JSON trees are transformed into lightweight normalized schemas without freezing UI interaction. - HMAC-Blinded Database Keys: Chat IDs and participant names in IndexedDB are indexed through HMAC hashes derived from your master passphrase, preventing forensic inspection of database keys even if the browser disk storage is inspected.
- Volatile Key Lifecycles: Passphrase stretching yields an AES-GCM encryption key that exists exclusively in memory. Pressing Lock, refreshing, or closing the tab drops the key reference.
- Streaming Media Extraction: Rather than unzipping entire multi-gigabyte archives into RAM, the zip parser reads directory records from the end of the file and extracts individual image/audio blobs only when scrolled into view.
Cryptographic Security Model
ChatViz treats browser storage as untrusted and implements defense-in-depth:
| Security Layer | Implementation Details |
|---|---|
| Key Derivation | PBKDF2-SHA256 with 600,000 iterations and a unique 16-byte cryptographic salt per vault. |
| Message Encryption | AES-256-GCM authenticated encryption for message text, participant names, and media blobs. |
| Key Blind Hashing | HMAC-SHA256 obscures search terms and primary keys inside IndexedDB stores. |
| Network Air Gap | connect-src 'none', object-src 'none', form-action 'none', and frame-ancestors 'none'. |
| Link Defense | External links require explicit confirmation dialogs and open with rel="noreferrer noopener". |
| Ephemeral Session | “View without saving” mode keeps chats in transient memory and clears all data on tab close. |
Technology Stack
Frontend & UI
- Framework: React 19 / Vite 8
- Styling: Tailwind CSS v4 with custom property tokens
- Virtualization:
@tanstack/react-virtual - Icons:
lucide-react - Typography: Bricolage Grotesque (display headline), Inter (interface text)
Parsing & Cryptography
- Off-Thread Processing: Dedicated Web Worker (
src/workers/parseWorker.js) - Zip Extraction:
fflatewith random-access slice reader - Encryption: WebCrypto API (
SubtleCryptoPBKDF2, AES-256-GCM, HMAC) - Local Storage: IndexedDB via
idb
Hosting & Deployment
- Platform: Cloudflare Workers Static Assets (
wrangler.jsonc) - Static Delivery: Zero server-side runtime code; pre-compiled static bundle
- Security Headers: Edge-enforced CSP, HSTS, frame-ancestors ‘none’, and referrer-policy via
_headers
Live Demo & Local Development
ChatViz is hosted and accessible at chatviz.nicx.dev.
To run or build ChatViz locally:
git clone https://github.com/nicx17/chatviz.git
cd chatviz
npm install
npm run dev # Start local development server
npm test # Run vitest test suite
npm run lint # Run eslint and code quality checks
npm run build # Compile production bundle with CSPProject Links & Reference
- Live Application: chatviz.nicx.dev
- Source Repository: github.com/nicx17/chatviz
- License: MIT License