ideas.
May 08, 2026 3 min read webdev-toolsdata

In-browser SQL workbench for CSV files

A web app that runs DuckDB in WebAssembly so analysts and developers can drag in CSV files, query them with SQL, and export results — no server, no signup, no data leaving the browser.

The idea

A single-page web app where you drop one or more CSV files, write SQL queries against them, and see results instantly. All processing runs in the browser via DuckDB-WASM. Results can be exported as CSV or rendered as simple charts. Nothing is sent to a server.

Why build this

Data analysts constantly need to do ad hoc queries on CSVs — finding duplicates, filtering rows, joining two exports from different tools. The current toolkit is either heavy (load it into Postgres, spin up a Jupyter notebook) or clunky (Excel filters, Google Sheets). A no-install browser tool that accepts real SQL fills that gap cleanly.

DuckDB-WASM is what makes this practical now. It ships a full columnar query engine to the browser — including joins, window functions, and GROUP BY — at reasonable speed for files up to a few hundred MB. A year ago this wasn't viable at acceptable performance; now it is, and no one has built a well-designed standalone UI around it.

The privacy angle matters too. Finance teams and HR departments deal with CSVs they cannot upload to a hosted service. A tool that runs entirely client-side removes that objection entirely.

Stack sketch

  • Frontend: Svelte + Vite (no React overhead needed for a focused tool like this)
  • Query engine: DuckDB-WASM (Apache-licensed, run inside a Web Worker to avoid blocking the UI thread)
  • Editor: CodeMirror 6 with the SQL language extension for syntax highlighting and autocomplete
  • Charts: Observable Plot (lightweight, composable, designed for tabular data)
  • File handling: File System Access API for drag-drop plus a fallback <input type="file"> for unsupported browsers
  • Distribution: single static HTML bundle — deploy to Cloudflare Pages, GitHub Pages, or any S3-compatible bucket

No backend. No database. No auth.

Scope for v1

  • Drag one or more CSV files; each becomes a queryable table named after its filename (spaces replaced with underscores)
  • SQL editor with syntax highlighting and a run shortcut (Ctrl+Enter)
  • Results grid with sortable columns and a row count
  • Export the current result set as CSV
  • Basic error display when a query is invalid or references a missing table
  • Deliberately out: chart rendering, query history, persistent sessions, Parquet support, file size validation beyond a soft warning at 200 MB

Where it could go

Chart generation is the most obvious follow-on. Observable Plot makes it tractable — the result of any SELECT can be piped into a line, bar, or scatter plot with minimal extra code. Pairing chart type selection with column-type inference (numeric vs categorical) would cover 80% of what analysts actually want to visualize without building a full BI tool.

A second path is persistent sessions. Everything vanishes on refresh right now. Saving the current query and file list to an IndexedDB entry — or encoding a small query into a URL hash — would let analysts return to work or share a reproducible analysis with a colleague without standing up any server infrastructure.

Watch out for

Files over ~300 MB will stall the UI unless all DuckDB execution stays inside the Web Worker and query dispatch is debounced; test against real-world "large export from Salesforce" files early to catch this before users do. Parquet support is tempting to add since DuckDB-WASM handles it natively, but it expands the feature surface fast — leave it for v2.