Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

dhanikk's avatar

πŸš€ DBStan Now Supports PostgreSQL

Hi everyone πŸ‘‹

I wanted to share a quick update on DBStan β€” the database analysis tool for Laravel.

We’ve just added support for PostgreSQL πŸŽ‰

πŸ” What’s New

DBStan can now analyze PostgreSQL databases and detect issues like:

Missing indexes (e.g., on foreign keys) Incorrect or missing relationships Risky nullable columns Inefficient data types (like using JSON instead of JSONB)

πŸ’‘ Why It Matters

PostgreSQL is widely used for high-performance and complex applications, but database issues can go unnoticed.

πŸ‘‰ DBStan helps catch them early β€” before they impact performance.

βš™οΈ How to Use

Just switch your DB connection:

DB_CONNECTION=pgsql

Run:

php artisan dbstan:analyze

That’s it β€” DBStan automatically detects PostgreSQL.

🎯 Goal

To provide consistent and reliable database analysis across both MySQL and PostgreSQL, helping developers build optimized and production-ready applications.

I’d really appreciate your feedback, suggestions, or contributions πŸ™Œ

Thanks!

0 likes
1 reply
imrandevbd's avatar

This is a solid update. Postgres support is huge, especially for catching those missing FK indexes that usually don't surface until you're under heavy load. I'm curious to see how the JSON vs JSONB analysis holds up on some of my messier schemas. Nice work on this!

Please or to participate in this conversation.