PHPackages                             lmz/medoo - 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. lmz/medoo

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

lmz/medoo
=========

The Lightest PHP database framework to accelerate development

v0.9.9(11y ago)044MITPHPPHP &gt;=5.1

Since Apr 28Pushed 10y ago1 watchersCompare

[ Source](https://github.com/liumingzhij26/Medoo)[ Packagist](https://packagist.org/packages/lmz/medoo)[ Docs](http://medoo.in)[ RSS](/packages/lmz-medoo/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (1)DependenciesVersions (8)Used By (0)

[![](https://raw.githubusercontent.com/catfan/Medoo/develop/src/medoo-logo.png)](https://raw.githubusercontent.com/catfan/Medoo/develop/src/medoo-logo.png)

[Medoo](http://medoo.in)
------------------------

[](#medoo)

> The Lightest PHP database framework to accelerate development

### Main Features

[](#main-features)

- **Lightweight** - Only 20KB with one file.
- **Easy** - Extremely easy to learn and use, friendly construction.
- **Powerful** - Support various common and complex SQL queries.
- **Compatible** - Support various SQL database, including MySQL, MSSQL, SQLite, MariaDB, Sybase, Oracle, PostgreSQL and more.
- **Security** - Prevent SQL injection.
- **Free** - Under MIT license, you can use it anywhere if you want.

### Get Started

[](#get-started)

```
// Include Medoo

// Initialize
$database = new \lmz\medoo\medoo([
    'database_type' => 'mysql',
    'database_name' => 'name',
    'server' => 'localhost',
    'username' => 'your_username',
    'password' => 'your_password',
    'charset' => 'utf8'
]);

// Enjoy
$database->insert('account', [
    'user_name' => 'foo'
    'email' => 'foo@bar.com',
    'age' => 25,
    'lang' => ['en', 'fr', 'jp', 'cn']
]);

// Or initialize from file and then
$database = new medoo();
```

### Contribution Guides

[](#contribution-guides)

For most of time, Medoo is using develop branch for adding feature and fixing bug, and the branch will be merged into master branch while releasing a public version. For contribution, submit your code to the develop branch, and start a pull request into it.

On develop branch, each commits are started with `[fix]`, `[feature]` or `[update]` tag to indicate the change.

Keep it simple and keep it clear.

### License

[](#license)

Medoo is under the MIT License.

### Links

[](#links)

- Official website:
- Documentation:

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity53

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 86.6% 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 ~65 days

Recently: every ~72 days

Total

6

Last Release

4073d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/0dabbb6e648e15b1a36128bf06e81d1cc928c28c226707d8b11540c1b8b05a75?d=identicon)[liumingzhij26](/maintainers/liumingzhij26)

---

Top Contributors

[![catfan](https://avatars.githubusercontent.com/u/1467904?v=4)](https://github.com/catfan "catfan (175 commits)")[![Angelaon](https://avatars.githubusercontent.com/u/13937887?v=4)](https://github.com/Angelaon "Angelaon (15 commits)")[![qatrix](https://avatars.githubusercontent.com/u/1537121?v=4)](https://github.com/qatrix "qatrix (5 commits)")[![IfnotFr](https://avatars.githubusercontent.com/u/1242308?v=4)](https://github.com/IfnotFr "IfnotFr (3 commits)")[![utopiaio](https://avatars.githubusercontent.com/u/2365328?v=4)](https://github.com/utopiaio "utopiaio (2 commits)")[![jackled](https://avatars.githubusercontent.com/u/2091208?v=4)](https://github.com/jackled "jackled (1 commits)")[![amoydavid](https://avatars.githubusercontent.com/u/734190?v=4)](https://github.com/amoydavid "amoydavid (1 commits)")

---

Tags

databasemysqlsqlitesqlmssqllightweightphp framework

### Embed Badge

![Health badge](/badges/lmz-medoo/health.svg)

```
[![Health](https://phpackages.com/badges/lmz-medoo/health.svg)](https://phpackages.com/packages/lmz-medoo)
```

###  Alternatives

[catfan/medoo

The lightweight PHP database framework to accelerate development

4.9k1.5M194](/packages/catfan-medoo)[doctrine/dbal

Powerful PHP database abstraction layer (DBAL) with many features for database schema introspection and management.

9.7k578.4M5.6k](/packages/doctrine-dbal)[cycle/database

DBAL, schema introspection, migration and pagination

64690.9k31](/packages/cycle-database)

PHPackages © 2026

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