PHPackages                             thedevsaddam/laravel-schema - 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. thedevsaddam/laravel-schema

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

thedevsaddam/laravel-schema
===========================

Display the connected database information in console.

2.0.3(9y ago)11627.9k—8.3%8[1 PRs](https://github.com/thedevsaddam/laravel-schema/pulls)1MITPHP

Since Aug 31Pushed 6y ago3 watchersCompare

[ Source](https://github.com/thedevsaddam/laravel-schema)[ Packagist](https://packagist.org/packages/thedevsaddam/laravel-schema)[ Docs](https://github.com/thedevsaddam/laravel-schema)[ RSS](/packages/thedevsaddam-laravel-schema/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (13)Used By (1)

Laravel Schema
==============

[](#laravel-schema)

This package will help to display database schema information from terminal.

---

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

[](#installation)

Via Composer

```
$ composer require thedevsaddam/laravel-schema
```

Install manually (add the line to composer.json file)

```
"thedevsaddam/laravel-schema": "^2.0"
```

Then open your terminal and hit the command

```
composer update
```

Add the following line to config/app.php file's *providers* array

```
Thedevsaddam\LaravelSchema\LaravelSchemaServiceProvider::class,
```

For *lumen* open bootstrap/app.php and add the line below

```
$app->register(Thedevsaddam\LaravelSchema\LaravelSchemaServiceProvider::class);
```

---

### **Available commands / Features**

[](#available-commands--features)

1. `php artisan schema:help` Display the available commands and usages.
2. `php artisan schema:simple` Display overall tables with total rows count.
3. `php artisan schema:list` Display all the available tables. schema information in list (*please see details below*).
4. `php artisan schema:show` Display all the available tables schema information in tabular form (*please see details below*).
5. `php artisan schema:table --t=yourTableName or --t=Namespace\\Model` Display a table's paginated data (*please see details below*).
6. `php artisan schema:query --r="wirte your raw sql query in double quote"` Perform a sql query.
7. `php artisan schema:monitor` Display database server status.

---

### **Usage in details**

[](#usage-in-details)

**Show Schema information in tabular form**

```
 php artisan schema:show
```

Example output: Schema information in tabular form

[![Schema information in tabular form](https://raw.githubusercontent.com/thedevsaddam/laravel-schema/master/screenshots/tabular.png)](https://raw.githubusercontent.com/thedevsaddam/laravel-schema/master/screenshots/tabular.png)

If you want to see a specific table then pass table name or Namespace\\\\Model

```
 php artisan schema:show --t=tableName or --t=Namespace\\Model
```

[![database info commandline](https://raw.githubusercontent.com/thedevsaddam/laravel-schema/master/screenshots/tabular-single.png)](https://raw.githubusercontent.com/thedevsaddam/laravel-schema/master/screenshots/tabular-single.png)

*Note: Same condition will be applied for tables **list** view*

**Show Schema information in List**

```
 php artisan schema:list
```

Example output: Schema information in list

[![database info commandline](https://raw.githubusercontent.com/thedevsaddam/laravel-schema/master/screenshots/list.png)](https://raw.githubusercontent.com/thedevsaddam/laravel-schema/master/screenshots/list.png)

Avaliable Options in **show** and **list**:

- `--t=tableName` or `-t tableName` to provide table name or Namespace\\Model
- `--c=connectionName` or `-c connectionName` to provide connection name

**Show Table names and total rows**

```
 php artisan schema:simple
```

Example output: Tables name with rows count

[![Tables name with rows count](https://raw.githubusercontent.com/thedevsaddam/laravel-schema/master/screenshots/simple.png)](https://raw.githubusercontent.com/thedevsaddam/laravel-schema/master/screenshots/simple.png)

*Note: You may pass `--c=connectionName` or `-c connectionName` to display a specific connection schema info*

**Show table definition**

```
 php artisan schema:table --t=tableName or --t=Namespace\\Model
```

Example output: Table definition with default page and limit

[![Table definition with default page and limit](https://raw.githubusercontent.com/thedevsaddam/laravel-schema/master/screenshots/table-pagination.png)](https://raw.githubusercontent.com/thedevsaddam/laravel-schema/master/screenshots/table-pagination.png)

Avaliable Options in **table**:

- `--t=tableName` or `-t tableName` to provide table name or Namespace\\\\Model (e.g: --t=App\\\\User or --t=users).
- `--p=pageNumber` or `-p PageNumber` to provide current page which you want to see
- `--o=orderBy` or `-o orderBy` to provide orderBy clause against a column (e.g: --o=id:desc or --o=id:asc \[default asc\]).
- `--l=rowsLimitPerPage` or `-l rowsLimitPerPage` to provide number of rows you want to display (e.g: --l=20).
- `--c=connectionName` or `-c connectionName` to provide connection name
- `--w=widthOfTableCell` or `-w widthOfTableCell` to provide character length of cell to show in tables (numeric \[default=10\]).
- `--s=columnName` to provide the column to display, you can provide comma (,) separated names to display (e.g: --s=name or --s=id,name).

```
php artisan schema:table --t=countries --p=4 --o=id:desc --l=25
```

**Perform raw sql query**

```
 php artisan schema:query --r="your sql query"
```

Example output: Query result will be dumped in console

[![Query result will be dumped in console](https://raw.githubusercontent.com/thedevsaddam/laravel-schema/master/screenshots/raw-query.png)](https://raw.githubusercontent.com/thedevsaddam/laravel-schema/master/screenshots/raw-query.png)

Avaliable Options in **query**:

- `--r=yourRawQuery` or `-r yourRawQuery` to provide your raw sql query (e.g: --r="select \* from someTable limit 20").
- `--c=connectionName` or `-c connectionName` to provide connection name (e.g: --c=mysql or -c sqlite)

**Monitor database server**

```
 php artisan schema:monitor
```

Example output: Showing the database status

[![Schema information in tabular form](https://raw.githubusercontent.com/thedevsaddam/laravel-schema/master/screenshots/monitoring-schema.png)](https://raw.githubusercontent.com/thedevsaddam/laravel-schema/master/screenshots/monitoring-schema.png)

You can pass --i=integerNumber as refresh time interval and --c=ConnectionName as well

```
 php artisan schema:monitor --i=3 --c=secondaryDatabase
```

---

### **License**

[](#license)

The **laravel-schema** is a open-source software licensed under the [MIT License](LICENSE.md).

*Thank you :)*

###  Health Score

40

—

FairBetter than 88% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity41

Moderate usage in the ecosystem

Community14

Small or concentrated contributor base

Maturity70

Established project with proven stability

 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 ~5 days

Total

12

Last Release

3483d ago

Major Versions

1.1.2 → 2.0.02016-09-19

### Community

Maintainers

![](https://www.gravatar.com/avatar/7c67f331d60f476035896c0e3ad603b3aa1f6b3fc4520146f1b6dbb949f3411c?d=identicon)[thedevsaddam](/maintainers/thedevsaddam)

---

Top Contributors

[![thedevsaddam](https://avatars.githubusercontent.com/u/9676798?v=4)](https://github.com/thedevsaddam "thedevsaddam (63 commits)")

---

Tags

database-info-commandlinelaravellaravel-schemaschemaschema-informationlaravelschemadatabasethedevsaddamlaravel-schemalaravel-database viewer

### Embed Badge

![Health badge](/badges/thedevsaddam-laravel-schema/health.svg)

```
[![Health](https://phpackages.com/badges/thedevsaddam-laravel-schema/health.svg)](https://phpackages.com/packages/thedevsaddam-laravel-schema)
```

###  Alternatives

[devio/eavquent

EAV modeling package for Eloquent and Laravel.

6410.4k](/packages/devio-eavquent)[dragon-code/laravel-data-dumper

Adding data from certain tables when executing the `php artisan schema:dump` console command

3418.6k](/packages/dragon-code-laravel-data-dumper)

PHPackages © 2026

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