MetalSQLite — GPU-Accelerated macOS SQLite Viewer
MetalSQLite is a native macOS app written in Swift that uses Apple's Metal GPU framework to render massive SQLite tables at 60fps. Bye bye beach balls. Hello instant data.
git clone https://github.com/darianmavgo/metalsqliteopen MetalSQLite.xcodeproj
# then Product → RunFeatures
A native macOS application that uses Apple Metal to render SQLite database tables at GPU speed.
Metal GPU Rendering
Leverages Apple Metal directly for GPU-accelerated cell drawing — handles millions of rows without a frame drop.
Native macOS
Pure Swift, AppKit, and Metal. No Electron, no web views. Instant launch, tiny memory footprint.
Full-Text Search
Instant fuzzy search across all columns in any table using SQLite FTS5.
Drag & Drop
Drop any .db or .sqlite file directly onto the window to open it immediately.
Documentation & Architecture
A high-performance SQLite viewer for macOS using Metal rendering and Go backend.
Architecture
- Go Backend: HTTP server using the Banquet URL parser for SQLite queries
- Swift Frontend: Native macOS app with Metal-accelerated table rendering
- Communication: REST API over localhost with dynamic port allocation
Quick Start
# Build and run everything
./rebuild-and-run.sh
This will:
- Stop any existing processes
- Build the Go server
- Build the Swift app
- Start the server on a random high port
- Launch the macOS app
- Run automated tests to verify everything works
Manual Scripts
# Build Go server only
./build-go.sh
# Build Swift app only
./build.sh
# Run without rebuilding
./run.sh
# Run tests
./test.sh
Components
Go Server (cmd/server/main.go)
- Parses Banquet URLs for SQLite queries
- Handles cross-origin requests
- Uses modernc.org/sqlite (CGO-free)
- Supports dynamic port allocation
Swift App
MetalSQLite/main.swift- Application entry pointMetalSQLite/AppDelegate.swift- App lifecycle and window managementMetalSQLite/TableViewController.swift- Table view and data management
Port Discovery
The Go server writes its port to /tmp/metalsqlite.port which the Swift app reads to discover the server.
Default Database
The app loads /Users/darianhickman/Documents/Index.sqlite by default, querying the tb0 table with a limit of 100 rows.
Troubleshooting
- Check server logs:
tail -f /tmp/metalsqlite-server.log - Check app logs:
tail -f /tmp/metalsqlite-app.log - Verify processes:
ps aux | grep -E 'metalsqlite|MetalSQLite' - Test server:
curl -X POST http://[::1]:<PORT>/query -H "Content-Type: application/json" -d '{"banquet_url":"..."}'
Stopping
pkill -f metalsqlite-server
pkill -f MetalSQLite
Known Issues
- The Banquet parser strips leading slashes from paths - this is handled automatically
- The Banquet parser may include table names in column selections - filtered automatically
Related Projects
More from the Mavgo ecosystem