PHPackages                             rollylni/liteconfig - 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. [Parsing &amp; Serialization](/categories/parsing)
4. /
5. rollylni/liteconfig

AbandonedArchivedLibrary[Parsing &amp; Serialization](/categories/parsing)

rollylni/liteconfig
===================

simplified work with config

2.1.0(5y ago)09MITPHPPHP &gt;=7.1

Since Apr 16Pushed 5y ago1 watchersCompare

[ Source](https://github.com/Rollylni/LiteConfig)[ Packagist](https://packagist.org/packages/rollylni/liteconfig)[ RSS](/packages/rollylni-liteconfig/feed)WikiDiscussions master Synced 1w ago

READMEChangelog (3)DependenciesVersions (4)Used By (0)

LiteConfig
==========

[](#liteconfig)

[Packagist](https://packagist.org/packages/rollylni/liteconfig)

- multifunctional
- the ability to add your own formats
- loading config by file extension
- 5 formats available by default

Example usage
=============

[](#example-usage)

```
require "vendor/autoload.php";

$cfg = new LiteConfig\Config("File.json"); //detect format by extension
$cfg->load([
    "default_formats" => ["yaml", "json", "ini", "enum", "serialize"],
    "default_key" => "default_value"
]);
$cfg->set("key", "value");
$cfg->save();
```

**File.json**:

```
{
   "default_formats": ["yaml", "json", "ini", "enum", "serialize"],
   "default_key": "default_value",
   "key": "value"
}
```

Make your own format
====================

[](#make-your-own-format)

```
require "vendor/autoload.php";

use LiteConfig\Format\Format;
use LiteConfig\Config;

class MyFormat extends Format {

    public function getName() {
        return "My own Format";
    }

    public function read(string $input): array {
         return json_decode(base64_decode($input));
    }

    public function write(array $input): string {
        return base64_encode(json_encode($input));
    }
}
$format = new MyFormat("json64");
$format->addAlias("js64");
Config::addFormat($format);
```

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity53

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

Total

3

Last Release

2022d ago

Major Versions

1.0.0 → 2.0.02020-11-02

PHP version history (2 changes)1.0.0PHP &gt;=7.0

2.0.0PHP &gt;=7.1

### Community

Maintainers

![](https://www.gravatar.com/avatar/6dc8a4f5a648b18f5a9a761c2b1057d679e72b51ded0eb5ded45b094773ed416?d=identicon)[Rollylni](/maintainers/Rollylni)

---

Top Contributors

[![Rollylni](https://avatars.githubusercontent.com/u/62455812?v=4)](https://github.com/Rollylni "Rollylni (52 commits)")

---

Tags

jsonenumconfigyamlini

### Embed Badge

![Health badge](/badges/rollylni-liteconfig/health.svg)

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

###  Alternatives

[hassankhan/config

Lightweight configuration file loader that supports PHP, INI, XML, JSON, and YAML files

97513.5M170](/packages/hassankhan-config)[thewunder/conphigure

Framework Agnostic Configuration Library

3115.9k](/packages/thewunder-conphigure)[m1/vars

Vars is a simple to use and easily extendable configuration loader with in built loaders for ini, json, PHP, toml, XML and yaml/yml file types. It also comes with in built support for Silex and more frameworks to come soon.

69124.2k1](/packages/m1-vars)[phppkg/config

Config manage, load, get. Supports INI,JSON,YAML,NEON,PHP format file

133.5k](/packages/phppkg-config)

PHPackages © 2026

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