PHPackages                             rafidalridwan/laravel-db-client - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Database &amp; ORM](/categories/database)
4. /
5. rafidalridwan/laravel-db-client

ActiveLibrary[Database &amp; ORM](/categories/database)

rafidalridwan/laravel-db-client
===============================

Lightweight database client for Laravel

v1.0.1(6mo ago)92MITBladePHP &gt;=8.1

Since Dec 31Pushed 6mo agoCompare

[ Source](https://github.com/rafidalridwan/laravel-db-client)[ Packagist](https://packagist.org/packages/rafidalridwan/laravel-db-client)[ Docs](https://github.com/rafidalridwan/laravel-db-client)[ RSS](/packages/rafidalridwan-laravel-db-client/feed)WikiDiscussions main Synced today

READMEChangelogDependencies (1)Versions (3)Used By (0)

Laravel DB Client
=================

[](#laravel-db-client)

A lightweight database client package for Laravel that provides a Blade UI to access your connected database, view tables, manage data, and run SQL queries.

**Repository:** [rafidalridwan/laravel-db-client](https://github.com/rafidalridwan/laravel-db-client)

Features
--------

[](#features)

- 📊 **View All Tables** - Browse all database tables with row counts and column information
- 🔍 **Table Data View** - View table data with pagination
- ✏️ **Add/Edit/Delete Rows** - Full CRUD operations on table data
- 🔐 **SQL Query Runner** - Execute SQL queries with security checks
- 🛠️ **Artisan Commands** - Run Laravel Artisan commands through the UI
- 🔒 **Security** - Built-in SQL injection protection and read-only mode support
- 📱 **Responsive UI** - Modern, clean interface

Installation
------------

[](#installation)

1. Install the package via Composer:

```
composer require rafidalridwan/laravel-db-client
```

The package is auto-discovered by Laravel.

2. Publish assets:

```
php artisan vendor:publish --tag=dbclient
```

Usage
-----

[](#usage)

1. Navigate to `/dbclient` in your browser (make sure you're authenticated if using auth middleware)
2. **Tables View** - Lists all tables with row counts

    - Click "View" to see table data
    - View table structure in collapsible section
    - Add, edit, or delete rows
3. **SQL Query** - Run custom SQL queries

    - Type your query and click "Execute"
    - Results are displayed in a table
    - Execution time is shown
    - Dangerous operations are blocked in read-only mode
4. **Artisan** - Run Laravel Artisan commands

    - Select from allowed commands
    - View command output

Security Features
-----------------

[](#security-features)

- **SQL Guard** - Blocks dangerous SQL operations (DROP, TRUNCATE, ALTER, CREATE, etc.)
- **Read-Only Mode** - When enabled, only SELECT queries are allowed
- **Table Name Sanitization** - Prevents SQL injection through table names
- **Middleware Protection** - Routes are protected by configurable middleware

Routes
------

[](#routes)

- `GET /dbclient` - Tables list
- `GET /dbclient/table/{table}` - View table data
- `GET /dbclient/table/{table}/rows` - Get paginated rows (JSON)
- `GET /dbclient/table/{table}/row/{id}` - Get single row (JSON)
- `POST /dbclient/table/{table}/insert` - Insert new row
- `PUT /dbclient/table/{table}/{id}/update` - Update row
- `DELETE /dbclient/table/{table}/{id}/delete` - Delete row
- `GET /dbclient/query` - SQL query interface
- `POST /dbclient/query/run` - Execute SQL query
- `GET /dbclient/artisan` - Artisan commands interface
- `POST /dbclient/artisan/run` - Run Artisan command

📸 Screenshots
-------------

[](#-screenshots)

### 📊 Tables Overview

[](#-tables-overview)

[![Tables Overview](screenshots/tables.png)](screenshots/tables.png)

### 🔍 Table Data View

[](#-table-data-view)

[![Table Data View](screenshots/table-view.png)](screenshots/table-view.png)

### 🏗️ Table Structure

[](#️-table-structure)

[![Table Structure](screenshots/table-info.png)](screenshots/table-info.png)

### 💻 SQL Query Runner

[](#-sql-query-runner)

[![SQL Query Runner](screenshots/sql-runner.png)](screenshots/sql-runner.png)

### 🛠 Artisan Commands

[](#-artisan-commands)

[![Artisan Commands](screenshots/artisan.png)](screenshots/artisan.png)

Requirements
------------

[](#requirements)

- PHP &gt;= 8.1
- Laravel &gt;= 8.0
- jQuery (included via CDN in views)

License
-------

[](#license)

MIT

###  Health Score

34

—

LowBetter than 75% of packages

Maintenance68

Regular maintenance activity

Popularity8

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity45

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

186d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/fc77283f2aa4d653594955843fb1ae506dffee10a784707154ba1b4b8214851d?d=identicon)[Rafid Al Ridwan](/maintainers/Rafid%20Al%20Ridwan)

---

Top Contributors

[![rafidalridwan](https://avatars.githubusercontent.com/u/67578066?v=4)](https://github.com/rafidalridwan "rafidalridwan (7 commits)")

---

Tags

db-clientjavasciptlaravelphpclientlaraveldatabasedatabase-managerdb-client

### Embed Badge

![Health badge](/badges/rafidalridwan-laravel-db-client/health.svg)

```
[![Health](https://phpackages.com/badges/rafidalridwan-laravel-db-client/health.svg)](https://phpackages.com/packages/rafidalridwan-laravel-db-client)
```

###  Alternatives

[illuminate/database

The Illuminate Database package.

2.8k54.9M11.7k](/packages/illuminate-database)[mongodb/laravel-mongodb

A MongoDB based Eloquent model and Query builder for Laravel

7.1k8.4M96](/packages/mongodb-laravel-mongodb)[yajra/laravel-oci8

Oracle DB driver for Laravel via OCI8

8793.2M25](/packages/yajra-laravel-oci8)[glushkovds/phpclickhouse-laravel

Adapter of the most popular library https://github.com/smi2/phpClickHouse to Laravel

2051.5M2](/packages/glushkovds-phpclickhouse-laravel)[aimeos/laravel-nestedset

Nested Set Model for Laravel

3714.4k6](/packages/aimeos-laravel-nestedset)[vectorial1024/laravel-cache-evict

Efficiently remove expired Laravel file/database cache data

5917.4k](/packages/vectorial1024-laravel-cache-evict)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
