Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>PG PilotNew to Visual Studio Code? Get it now.
PG Pilot

PG Pilot

BookMyGarage

|
36 installs
| (4) | Free
PostgreSQL client for VS Code — manage connections, run queries, and view results inline.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

PG Pilot

Lightweight PostgreSQL client for Visual Studio Code.

Features

  • Sidebar connection manager: add, edit, test, duplicate, and remove connections
  • Schema browser: databases, schemas, tables, views, columns, and functions
  • Function SQL file navigation: open <function>.sql files from function tree items
  • Query execution: run full editor SQL or selected SQL
  • Results panel: multi-statement tabs, filtering, JSON expand/copy, CSV/JSON export
  • Query history: re-open previous queries
  • Status bar: active connection and database context
  • Guardrails: destructive query confirmation and optional auto-LIMIT for SELECT
  • Copilot Chat tools: list/connect/inspect schema/run query/query history

Keybindings

Key Action
Shift+Enter Run SQL in current editor (selection if present, otherwise full editor)
Cmd/Ctrl+Shift+Enter Run selected SQL only
Ctrl+Shift+Q (Windows/Linux), Cmd+Option+Q (macOS) Open a new untitled SQL editor

Notes:

  • Keybindings apply in SQL editors (resourceLangId == sql).
  • .sql and .pgsql files are registered to SQL in this extension.

Settings

Setting Default Description
pgPilot.maxResultRows 500 Max rows displayed per statement result
pgPilot.queryTimeout 30000 Per-session statement timeout in milliseconds (0 = no timeout)
pgPilot.autoLimit false Append LIMIT <maxResultRows> to SELECT statements that do not already contain a LIMIT
pgPilot.showExecutionTime true Show execution duration in results panel metadata
pgPilot.confirmDestructiveQueries true Confirm before top-level DROP, TRUNCATE, or DELETE without WHERE
pgPilot.historySize 100 Maximum number of queries stored in history
pgPilot.defaultSslMode prefer Default SSL mode preselected when creating new connections

Security and Data Storage

  • Connection metadata (name/host/port/user/database/SSL/color) is stored in extension globalState.
  • Connection passwords and connection strings are stored in VS Code SecretStorage.
  • Existing plaintext credentials from older versions are migrated to SecretStorage on activation.
  • Query history is stored locally in extension globalState.
  • No telemetry is emitted by this extension.

Getting Started

  1. Open the PostgreSQL view in the Activity Bar.
  2. Click Add Connection.
  3. Enter credentials (or a connection string) and save.
  4. Connect to the new connection from the tree.
  5. Open a .sql file (or create a new query editor with Ctrl+Shift+Q on Windows/Linux or Cmd+Option+Q on macOS).
  6. Run with Shift+Enter.

Development

npm install
npm run compile
npm run lint

Run in VS Code Extension Development Host with F5.

Packaging

npx @vscode/vsce package --no-dependencies -o pg-pilot.vsix
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft