An exact, faithful replica of PostgreSQL (pgAdmin 4) — running entirely in your browser.
No server. No installation. No subscription. No AI API. Works offline after first load. 26 enterprise-grade features.
Built by Adewale Samson Adeagbo — Data Scientist · EdTech Builder · Virtual Tutor · AI-Augmented Solutions Developer · DataTech Builder · FaithTech Builder
🚀 Live Demo · 📖 Docs · 📋 SQL Ref · 🐛 Issues · 👤 Author
PostgreSQL (pgAdmin) Simulator is a faithful, exact replica of pgAdmin 4 — the official graphical administration tool for PostgreSQL. Every design element, every menu structure, every workflow has been carefully modeled after the real pgAdmin 4 interface:
- Server Browser Tree:
🖥 PostgreSQL 15→🗄 queryforge→📁 public→📋 Tables— exactly like pgAdmin's object browser - Properties Panel: Connection info, database stats, table metadata — mirrors pgAdmin's right-side properties
- Query Editor: Multi-tab, line-numbered, with pgAdmin-style toolbar — write, format, execute PostgreSQL
- Dashboard: Server activity, session information, resource gauges — real-time monitoring
- Menus: File, Edit, Query, Schema, Tools, Samples, Help — organized like pgAdmin's top menu bar
- Status Bar: Engine info, database name, table/row counts, transaction indicators, query timing sparkline
Under the hood: sql.js (SQLite compiled to WebAssembly) with a 20+ rule PostgreSQL compatibility layer. Write standard PostgreSQL syntax — ::type casts, ILIKE, SERIAL, NOW(), DATE_TRUNC, EXTRACT, STRING_AGG, window functions, CTEs — and it just works.
Originally built on and for the ITEL Vista Tab 30s Android tablet. Runs on any device with a modern browser.
Adewale Samson Adeagbo
Data Scientist | EdTech Builder | Virtual Tutor | AI-Augmented Solutions Developer | DataTech Builder | FaithTech Builder
This simulator was born from real necessity. For 15+ years I have taught in Nigerian classrooms — Nursery through Secondary — across Mathematics, Further Mathematics, Physics, Chemistry, and Computer Science. My primary device is an ITEL Vista Tab 30s Android tablet. I needed a full PostgreSQL environment for my data science practice and for teaching SQL to students — but you cannot install PostgreSQL or pgAdmin on an Android tablet.
So I built this simulator. Not as a web developer (I am a data scientist), but by thinking clearly about the problem and leveraging AI as a force multiplier to operate competently in unfamiliar technical territory. The same working method that built CBT Pro — my free exam platform used by real students — built this tool. Zero budget. Android tablet. One clear problem.
This simulator is part of the HMG Technologies ecosystem under HMG Concepts, alongside HMG Academy — a full-service virtual school serving Nigerian students at every level.
Current Programmes (May 2026):
- 🌺 DeepTech_Ready — DSN × 3MTT × Google.org (DSML Track, Cohort 3) — Active
- 🌺 WorldQuant University — Applied Data Science Lab — Active
- 🌺 Kodecamp Cohort 6 — Machine Learning Core Track — Active
- 🌺 IBM SkillsBuild Hub Ambassador — Cohort 4
| Contact | Detail |
|---|---|
| 🌐 Portfolio | cssadewale.pages.dev |
| linkedin.com/in/adewalesamsonadeagbo | |
| 🐙 GitHub | github.com/cssadewale |
| 🏫 HMG Academy | hmgacademy.pages.dev |
| 🏢 HMG Concepts | hmgconcepts.pages.dev |
| 📺 YouTube | youtube.com/@hmgconcepts |
| +234 810 086 6322 | |
| 📞 Phone | +234 809 448 1488 |
| hismarvellousgrace@gmail.com · buildingmyictcareer@gmail.com | |
| 📍 Location | Lagos / Ogun State, Nigeria 🇳🇬 |
| Category | Features |
|---|---|
| pgAdmin 4 UI | Exact replica: Server Browser Tree, Properties Panel, Dashboard, Menubar, Toolbar, Status Bar |
| PostgreSQL Engine | sql.js WASM + 20-rule PG compatibility layer. All SELECT/JOIN/CTE/Window/DML/DDL/Transactions |
| Editor | Multi-tab, line numbers, SQL formatting, find & replace (regex), auto-close brackets, smart autocomplete |
| Data | CSV/JSON/TSV import, 7 sample datasets (up to 3,300 rows), drag & drop, type inference, batch insert |
| Results | Sortable grid, filter bar, color-coded cells, row detail, keyboard navigation, cell context menu |
| Visualization | Bar, Line, Pie, Doughnut, Scatter charts (Chart.js 4.4) |
| Pivot Table | Cross-tabulate with SUM/COUNT/AVG/MIN/MAX |
| Explain | Text-based Explain Plan + Graphical Plan Tree with color-coded nodes (v4.0) |
| Transactions | BEGIN/COMMIT/ROLLBACK with amber status banner |
| Export | CSV, JSON, Excel TSV, INSERT SQL, Markdown, HTML table, PDF/Print — plus Export Wizard (v4.0) |
| Enterprise | 14 enterprise features (see below) — DB Search, Activity Monitor, Macros, Data Generator, Health Report, Schema Diff, Data Dictionary, Tab Groups, Maintenance Wizard, Snippet Manager, Result Diff, Extended Stats, Connection Manager |
Total: 67+ features across all tool categories
Access: Run a query, then go to the Explain tab (or press Ctrl+E). The graphical tree appears below the text-based plan.
What it does: Renders your query's execution plan as an interactive, visual tree — just like pgAdmin's graphical EXPLAIN. Each node represents an operation (SORT, HASH AGGREGATE, HASH JOIN, FILTER, SEQ SCAN, INDEX SCAN) with cost estimates, row estimates, and performance badges. Nodes are color-coded: root nodes in blue, leaf nodes in dark tone. Badges mark operations as SLOW (red), FAST (green), or EXPENSIVE (amber). Hover for details.
Why it matters: Visual execution plans are an enterprise database administration staple. They make query optimization intuitive — you can immediately see whether a full table scan (SEQ SCAN on a large table) is hurting performance.
Access: Tools → Database Search (or Ctrl+Shift+F in the search modal).
What it does: Searches every value in every column of every loaded table simultaneously. Enter any search term and the engine scans all tables, returning matching rows with table name, column name, and the full value displayed. Click any result to auto-generate a SELECT query that finds that exact row. Searches up to 50 matches across thousands of rows in milliseconds.
Why it matters: In real database administration, finding where a specific value exists across dozens of tables is a common and tedious task. This feature replicates pgAdmin's "Search Objects" capability — find anything, anywhere, instantly.
Access: Results → 📡 Monitor tab.
What it does: A real-time dashboard showing:
- Server Resources: CPU and memory gauge bars with percentage and color (green/amber/red)
- Active Sessions: Simulated PostgreSQL sessions with PID, current query, state (active/idle/waiting/locked), and duration
- Connection Pool: Visual 10-slot connection pool indicator (green=used, amber=waiting, grey=idle)
- Throughput Statistics: Total queries executed, average execution time, table count, row count, transaction status
Why it matters: pgAdmin's Dashboard tab is one of its most-used features for DBAs. This monitor gives you the same operational awareness — see server health, spot long-running queries, and monitor connection utilization.
Access: Results → 🧬 Generator tab.
What it does: Generate realistic test datasets with a few clicks. Choose from 5 templates:
- Users: id, name, email, age, city — with realistic names, emails, and Nigerian/African cities
- Orders: id, customer_id, product, amount, order_date — randomized e-commerce data
- Products: id, name, category, price, stock_qty — inventory-style data
- System Logs: id, timestamp, level (INFO/WARN/ERROR/DEBUG), message, source — log analytics data
- IoT Sensors: id, timestamp, temperature, humidity, pressure — time-series sensor readings
Configure row count (1–10,000), table name, and click Generate. The table is created, populated in batches of 300, and auto-selected for immediate querying.
Why it matters: Enterprise testing and development require realistic data. This generator provides instant test datasets for performance benchmarking, query development, and learning — no external data files needed.
Access: Results → ⏺ Macros tab.
What it does: Record a sequence of SQL queries and replay them with a single click. Click Record, run your queries normally, and every execution is captured. Click Stop when done. The macro stores up to 50 steps with their SQL content and execution times. Click Play All to replay the entire sequence automatically with 300ms pauses between steps.
Why it matters: Database administrators and developers frequently run the same multi-step sequences (e.g., "create temp table → load data → run aggregation → export results"). Macros automate this workflow. Think of it as pgAdmin's Query Tool session recording.
Access: Results → Δ Diff tab.
What it does: Compare two query result sets row-by-row. Run your first query, then click 📸 Snapshot to capture it. Run a second query (perhaps after changing a WHERE clause, or using a different table), then click Δ Compare. The diff shows:
- Matching rows count (✅, in green)
- Rows only in the snapshot (❌, in red — these were "removed")
- Rows only in the current results (➕, in green — these are "new")
- Side-by-side panels showing up to 20 rows from each side
Why it matters: When testing query changes, you need to know exactly what changed in the output. This replicates the data comparison functionality that enterprise DBAs use to validate query modifications, ETL transformations, and database migrations.
Access: Results → 🔧 Maint tab.
What it does: Perform PostgreSQL-standard table maintenance operations:
- VACUUM: Reclaims storage occupied by deleted rows. In SQLite (our engine), runs the VACUUM command to rebuild the database file and recover space. Shows completion status and row counts.
- ANALYZE: Updates table statistics used by the query planner. Equivalent to PostgreSQL's ANALYZE — recomputes index statistics for optimal query planning.
- REINDEX: Rebuilds all indexes on the selected table. Critical after heavy INSERT/UPDATE/DELETE operations to restore index performance.
Select any table from the dropdown and run any operation. Results display with timing.
Why it matters: These are the three most common PostgreSQL maintenance commands that every DBA runs regularly. This feature teaches proper database maintenance workflows in a safe, simulated environment.
Access: Results → 🩺 Health tab → Run Health Check.
What it does: Runs a comprehensive 6-point diagnostic check on your database:
- Tables present — are there tables loaded?
- No empty tables — do all tables contain data?
- Column naming — do columns follow snake_case conventions?
- Primary keys — do all tables have identifiable ID/key columns?
- Indexes present — are there user-created indexes for performance?
- Row balance — are row counts reasonably distributed across tables?
Generates a percentage score with letter grade (A/B/C/D) and specific, actionable recommendations:
- "Add PRIMARY KEY columns to tables without identifiers"
- "Run ANALYZE to update query planner statistics"
- "Use Index Advisor (Ctrl+I) for indexing suggestions"
- "Run pg_dump Backup regularly"
Why it matters: Enterprise database administration includes regular health assessments. This automated report identifies structural issues before they become performance problems — just like the health checks built into managed PostgreSQL services.
Access: Tools → Export Data Wizard.
What it does: A 4-step guided wizard for exporting data:
- Step 1: Select source — choose a table or use current query results. Shows row counts.
- Step 2: Choose format — CSV, JSON, TSV (Excel), INSERT SQL, Markdown, or HTML table. Configure options (include headers, NULL handling).
- Step 3: Row selection — all rows or first N rows.
- Step 4: Review summary and export. Click to download.
Progress dots at the top show your position in the wizard. Back/Next navigation is intuitive.
Why it matters: pgAdmin includes an Export dialog with format options. This wizard goes further, providing a structured, guided experience ideal for users who export data regularly — analysts, report generators, and data migration workflows.
Access: Tools → Custom Snippet Manager.
What it does: Create, store, and manage your own SQL snippet templates. Each snippet has:
- Name — descriptive label (e.g., "Monthly Revenue by Region")
- Category — organize snippets (e.g., "Reports", "ETL", "Analytics")
- SQL Code — the full query template
Snippets persist in your browser's localStorage. Click any snippet to load it into the editor. Delete snippets you no longer need. Your custom snippets appear alongside the built-in 69-snippet library.
Why it matters: Every DBA and analyst accumulates their own library of frequently-used queries. The Snippet Manager gives you a personal query library that travels with your browser — no database needed, just localStorage.
Access: Tools → Tab Session Groups.
What it does: Save all currently open query tabs as a named group. Later, load that group to restore your entire workspace — all tabs, all SQL content, exactly as you left them. Perfect for:
- Project switching: "Sales Analysis" group vs. "HR Analytics" group
- Teaching: Prepare a group of example queries and load them during class
- Context preservation: Save your work before closing the browser
Groups persist in localStorage. Create unlimited groups. Load any group with one click.
Why it matters: pgAdmin saves query tabs between sessions on a real server. Since this simulator has no server, Tab Groups provide equivalent functionality — named, persistent workspace sessions.
Access: Tools → Data Dictionary.
What it does: Generates a complete metadata document for all loaded tables. For each table, displays:
- Table name, row count, and column count
- Column-by-column breakdown: position number, column name, data type (with color-coded type pills), and primary key indicators (🔑)
- Clean, tabular format
Click Export as Markdown to download a formatted .md file suitable for documentation, GitHub wikis, or sharing with team members.
Why it matters: Data dictionaries are essential enterprise documentation artifacts. They answer "what data do we have and what does each column mean?" — critical for onboarding, compliance, and data governance.
Access: Right panel → Stats tab (after running a query with numeric columns).
What it does: Enhanced column statistics with visual histograms. For every numeric column, displays:
- 10-bucket histogram bars with height proportional to frequency
- Min/Max range labels
- Unique count and percentage
- Average ± Standard Deviation
- Null count and non-null count
Histogram bars are interactive (hover for exact count) and color-coded via the PostgreSQL blue palette.
Why it matters: Understanding data distribution is fundamental to data science and database optimization. Histograms reveal skew, outliers, and distribution shape at a glance — going far beyond simple MIN/MAX/AVG.
Access: Visible in 📡 Monitor tab and Properties panel.
What it does: Simulates a PostgreSQL connection pool:
- Visual 10-slot connection pool indicator
- Color coding: green (in use), amber (waiting), grey (idle)
- Server host and port display:
localhost:5432 - Engine identification: "PostgreSQL 15 Compatible"
- Transaction status: auto-commit or active transaction
Why it matters: Connection pooling is an enterprise PostgreSQL concept. This visualization teaches what connection pools look like and how they behave — valuable learning for aspiring DBAs.
| # | Feature | How to Access | What It Does |
|---|---|---|---|
| 1 | ⏱ Query Performance Benchmark | Results → ⏱ Bench tab | Run query N times (1-100), get avg/min/max/stddev with histogram. Color-coded: 🟢 Fast (<200ms), 🟡 Medium (<1s), 🔴 Slow (>1s) |
| 2 | 🔄 Auto-Refresh Scheduler | Results → 🔄 Refresh tab | Set interval (5-3600s). Query auto-reruns. Countdown display. Start/Stop control. Perfect for monitoring dashboards |
| 3 | 📸 Database Snapshots (Time Travel) | Results → 📸 Snap tab | Save complete database state (all tables + data) as named snapshot. Restore anytime. Export all snapshots as JSON. Up to 20 stored |
| 4 | 🔒 Column Masking (Data Privacy) | Results → 🔒 Mask tab | Toggle columns to show/hide values. Masked cells display "•••hidden•••". Privacy-preserving data sharing within same session |
| 5 | ⚠ Deadlock Simulator (Educational) | Results → ⚠ Lock tab | Simulates transaction deadlock with detailed step-by-step log. Shows lock acquisition, circular wait detection, PostgreSQL auto-resolution, prevention tips |
| 6 | ✨ Advanced SQL Formatter | Results → ✨ Format tab | 3 formatting presets: Compact (minimal), Expanded (pgAdmin default), Aligned (columns vertically aligned). One-click apply |
| 7 | 🔖 Result Bookmarks | Results → 🔖 Bkmk tab | Bookmark interesting rows from query results. 50-bookmark capacity. Click to view full row data. Persists in localStorage |
| 8 | 🔍 SQL History Comparator | Tools → SQL History Comparator | Side-by-side comparison of any two queries from execution history. Color codes: red/strikethrough = removed lines. See exactly what changed between versions |
| 9 | 🔗 Table Dependency Graph | Tools → Table Dependency Graph | Visual dependency map inferred from _id column suffixes. Shows which tables reference which. Click any table to SELECT from it |
| 10 | 📋 JSON Cell Pretty-Printer | Right-click cell → View full content | Auto-detects JSON strings and renders them with syntax highlighting (keys=blue, strings=green, numbers=amber, booleans=cyan, null=grey) |
| 11 | 📥 Enhanced AutoFormat on Paste | Editor (Ctrl+V) | Detects pasted SQL and preserves intentional formatting for large scripts |
| 12 | 🔖 Row Bookmark Button | Double-click any result row | "Bookmark This Row" button appears in Properties panel after viewing row detail. One-click bookmarking |
A dedicated enterprise toolbar sits between the main toolbar and the workspace, giving one-click access:
- ⏱ Benchmark | 🔄 Scheduler | 📸 Snapshots | 🔒 Mask | ⚠ Deadlock | ✨ Format+ | 🔖 Bkmk | 📥 Export Snap
Open the deployed URL in any browser. No installation. Works on ITEL Vista Tab 30s and all devices.
- Download
index.htmlfrom this repository - Transfer to your device (USB, WhatsApp, Google Drive, Bluetooth)
- Open in Google Chrome (required for best WebAssembly performance)
- First load: ~3MB SQL engine downloads from CDN (internet needed once)
- After that: works completely offline. Bookmark for easy access.
See DEPLOYMENT.md for complete instructions covering GitHub Pages, Netlify, Cloudflare Pages, Vercel, and local use. ITEL Vista Tab 30s-specific transfer methods included.
| Tool | Version | Purpose | License |
|---|---|---|---|
| sql.js | 1.11.0 | SQLite WASM — PostgreSQL-compatible engine | MIT |
| Chart.js | 4.4.1 | Interactive charts | MIT |
| PapaParse | 5.4.1 | CSV/TSV parsing | MIT |
| HTML5/CSS3/JS | Vanilla | Complete UI — pgAdmin 4 replica | — |
No npm. No Node.js. No build tools. No frameworks. No server. No AI API calls. Single HTML file (~400KB). Opens on any device. Works offline.
pgadmin-simulator/
├── index.html ← Complete application (single file, ~400KB)
├── README.md ← This file
├── DEPLOYMENT.md ← Deployment guide (5 options, ITEL-specific)
├── SQL_REFERENCE.md ← Complete SQL reference (18 sections, 100+ examples)
├── CHANGELOG.md ← Full version history (v1.0 → v4.0)
├── CONTRIBUTING.md ← How to contribute
├── SECURITY.md ← Security policy & architecture
└── LICENSE ← MIT License
MIT License — see LICENSE. Free for personal, educational, and commercial use.
- sql.js — SQLite WASM
- Chart.js — charts
- PapaParse — CSV parsing
- PostgreSQL — the database standard we emulate
- pgAdmin — the UI we faithfully replicate
🐘 PostgreSQL (pgAdmin) Simulator v4.0 Ultimate — "The Elephant Edition"
Built with ❤️ by Adewale Samson Adeagbo · Nigeria 🇳🇬
"I did not wait to become a developer. I used clear thinking and AI leverage to build the tools my students needed."
"Making PostgreSQL accessible on every device, everywhere — no server required."