Skip to content
| Marketplace
Sign in
Visual Studio Code>Data Science>ViewstorNew to Visual Studio Code? Get it now.
Viewstor

Viewstor

Siyet

|
1 install
| (0) | Free
Database management tool for VS Code — browse schemas, run queries, and inspect data across PostgreSQL, Redis, and ClickHouse.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Viewstor

Viewstor

License VS Code ZeroVer

PostgreSQL + Redis + ClickHouse in one extension.
Free. Open source. No paywalls.


Why Viewstor?

Database extensions for VS Code are either locked to one database, or freemium with crippled free tiers (limited connections, no export, closed source). Switching between DBeaver and VS Code breaks flow. DataGrip costs money.

Viewstor is a free, open-source extension that covers PostgreSQL, Redis, and ClickHouse in a single tool — with features you won't find elsewhere:

Viewstor Database Client SQLTools DBCode
Price Free forever Freemium Free Freemium
Open source AGPL-3.0 Closed (since v4.7) MIT Closed
PG + Redis + CH All free Free tier limits No Redis Redis/CH paid
Safe mode Block / Warn / Off No No No
Copilot Chat participant @viewstor No No No
MCP for AI agents Built-in, free No No Paid tier
Import from DBeaver/DataGrip/pgAdmin Yes No No No
Index hints Yes No No No
Color-coded folders Nested, inherited No No No

Get Started

Install from the VS Code Marketplace:

ext install Siyet.viewstor

Or search Viewstor in the Extensions panel (Ctrl+Shift+X).

Migrating from another tool?

Ctrl+Shift+P → Viewstor: Import Connections → pick your format:

  • DBeaver — data-sources.json
  • DataGrip — dataSources.xml
  • pgAdmin — servers.json

Passwords are excluded for security — you'll enter them on first connect. See the Wiki for detailed migration guides.


Features

Safe Mode

Production databases deserve guardrails. Safe mode runs EXPLAIN before every SELECT and catches sequential scans on large tables:

Mode Behavior
Block Blocks queries with Seq Scan. Shows EXPLAIN plan
Warn Warning with "Run Anyway" / "See EXPLAIN" / "Cancel"
Off No checks

Set globally in settings or per connection. Auto-adds LIMIT to SELECTs that don't have one.

Read-only Mode

Mark a connection or an entire folder as read-only. Child connections inherit the setting. Mutations are blocked in the query editor, result grid, and MCP commands.

Connections

  • Nested folders with drag-and-drop for connections and folders
  • Multi-database — list several databases in one connection, each as a separate tree node
  • Color coding — theme-aware palette or hex picker, tints icons; folders pass color to children
  • SSL and SSH tunnel / SOCKS5 proxy support

Schema Browser

  • Tree: databases → schemas → tables, views, indexes, triggers, sequences
  • Auto-collapse single-database and single-schema levels
  • Hide schemas/databases from context menu
  • Inaccessible objects (no permissions) rendered in error color

Query Editor

  • Per-connection SQL tabs (Ctrl+Enter to execute)
  • SQL autocomplete — context-aware: tables after FROM/JOIN, columns from referenced tables, table.column dot trigger, alias resolution
  • Index hints — warning diagnostics on WHERE/ORDER BY columns without an index
  • Cancel running queries (PG: pg_cancel_backend, CH: AbortController)

Result Grid

  • Server-side pagination (50 / 100 / 500 / 1000 rows)
  • Estimated row count from statistics, exact count via refresh
  • Inline editing with PK-based UPDATE (disabled in read-only)
  • Column sorting (shift-click for multi-column)
  • Cell selection with drag, Shift+Click range, resize handle
  • Search with Ctrl+F, Enter to cycle matches

Export & Copy

  • Export all rows (not just current page) — CSV, TSV, JSON, Markdown
  • Right-click cells → Copy as CSV / TSV / Markdown / JSON
  • Ctrl+C copies selected cells as TSV

Copilot Chat (@viewstor)

Ask questions about your database in natural language:

  • @viewstor describe the users table
  • @viewstor write a query to find orders without payments
  • @viewstor what indexes are missing for this query?

Schema context is injected automatically from the active connection. Slash commands: /schema, /query, /describe. Requires GitHub Copilot.

AI Agent Integration (MCP)

Two MCP interfaces — pick the one that fits your workflow:

VS Code MCP commands (for Copilot, Cursor — agents running inside VS Code):

Command What it does
viewstor.mcp.listConnections List connections with status
viewstor.mcp.getSchema Flattened schema (tables, columns, types)
viewstor.mcp.executeQuery Run SQL (read-only enforced)
viewstor.mcp.getTableData Fetch rows with limit
viewstor.mcp.getTableInfo Column metadata, PKs, nullability

Standalone MCP server (for Claude Code, Cline — CLI agents running outside VS Code):

{
  "mcpServers": {
    "viewstor": {
      "command": "node",
      "args": ["/path/to/viewstor/dist/mcp-server.js"]
    }
  }
}

7 tools: list_connections, get_schema, execute_query, get_table_data, get_table_info, add_connection, reload_connections. Reads connections from ~/.viewstor/connections.json and .vscode/viewstor.json. Connections sync bidirectionally with the VS Code extension. See the MCP Server wiki page for setup instructions.

All MCP interfaces auto-connect and respect read-only mode.

Other

  • Query history with execution time and row count
  • DDL viewer for tables, views, indexes, triggers, sequences
  • JSON/JSONB cell editor (double-click to open)
  • PostgreSQL arrays displayed with {curly braces}
  • Redis — inspect strings, lists, sets, sorted sets, hashes

Keyboard Shortcuts

Shortcut Action
Ctrl+Enter / Cmd+Enter Run query (or selected text)
Ctrl+F / Cmd+F Search in result grid
Enter (in search) Next match
Ctrl+C / Cmd+C Copy selected cells
Esc Close popups

All shortcuts use physical key codes — work on any keyboard layout.

Supported Databases

Database Protocol Library
PostgreSQL TCP pg
Redis TCP ioredis
ClickHouse HTTP @clickhouse/client

Development

Prerequisites

  • Node.js 18+
  • VS Code 1.93+
  • Docker (for e2e tests)

Commands

npm run dev          # development build
npm run watch        # rebuild on changes
npm run build        # production build
npm run lint         # ESLint check
npm run lint:fix     # auto-fix
npm test             # unit tests (vitest)
npm run test:e2e     # e2e tests (Docker required)
npm run package      # .vsix package

Testing

Unit tests use vitest. E2E tests use testcontainers to spin up PostgreSQL, Redis, and ClickHouse in Docker. Auto-skipped if Docker is unavailable.

CI/CD

  • CI (on PR, trunk push, tags): lint → unit tests → build → npm audit
  • Release (on v* tag): build → test → publish to Marketplace → GitHub Release with .vsix

Contributing

See CONTRIBUTING.md.

Changelog

See CHANGELOG.md for a full list of changes per version.

License

AGPL-3.0

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft