PHPackages                             turkialawlqy/laravel-settings - 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. turkialawlqy/laravel-settings

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

turkialawlqy/laravel-settings
=============================

Store key value pair in database as settings

1.0.2(4y ago)1121MITPHPPHP ^7.3|^8.0

Since Oct 25Pushed 4y ago2 watchersCompare

[ Source](https://github.com/turkialawlqy/laravel-settings)[ Packagist](https://packagist.org/packages/turkialawlqy/laravel-settings)[ Docs](https://github.com/turkialawlqylaravel-settings)[ RSS](/packages/turkialawlqy-laravel-settings/feed)WikiDiscussions main Synced 3d ago

READMEChangelog (1)Dependencies (4)Versions (4)Used By (1)

Laravel Settings
----------------

[](#laravel-settings)

[![Latest Version on Packagist](https://camo.githubusercontent.com/6d71e35760b7a3a6a6abd3670c6b35c5583b1f9ae7499c96bc6fdf7efc0f4757/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f7475726b69616c61776c71796c61726176656c2d73657474696e67732e737667)](https://packagist.org/packages/turkialawlqy/laravel-settings)[![Software License](https://camo.githubusercontent.com/074b89bca64d3edc93a1db6c7e3b1636b874540ba91d66367c0e5e354c56d0ea/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e737667)](LICENSE.md)[![StyleCI](https://camo.githubusercontent.com/7ec68caf1a62933861f6800521b086fac2f0d0b9740eab1cd1d2db169e62044c/68747470733a2f2f7374796c6563692e696f2f7265706f732f3135323235383034342f736869656c64)](https://styleci.io/repos/152258044)

Use `turkialawlqy/laravel-settings` to store key value pair settings in the database.

> All the settings saved in db is cached to improve performance by reducing sql query to zero.

### Installation

[](#installation)

**1** - You can install the package via composer:

```
$ composer require turkialawlqy/laravel-settings
```

**2** - If you are installing on Laravel 5.4 or lower you will be needed to manually register Service Provider by adding it in `config/app.php` providers array and Facade in aliases arrays.

```
'providers' => [
    //...
    turkialawlqy\Settings\SettingsServiceProvider::class
]

'aliases' => [
    //...
    "Settings" => turkialawlqy\Settings\Facade::class
]
```

In Laravel 5.5 or above the service provider automatically get registered and a facade `Setting::get('app_name')` will be available.

**3** - Now run the migration by `php artisan migrate` to create the settings table.

Optionally you can publish migration by running

```
php artisan vendor:publish --provider="turkialawlqy\Settings\SettingsServiceProvider" --tag="migrations"

```

### Getting Started

[](#getting-started)

You can use helper function `settings('app_name')` or `Settings::get('app_name')` to use laravel settings.

### Available methods

[](#available-methods)

```
// Pass `true` to ignore cached settings
settings()->all($fresh = false);

// Get a single setting
settings()->get($key, $defautl = null);

// Set a single setting
settings()->set($key, $value);

// Set a multiple settings
settings()->set([
   'app_name' => 'turkialawlqy',
   'app_email' => 'turkialawlqy@email.com',
   'app_type' => 'SaaS'
]);

// check for setting key
settings()->has($key);

// remove a setting
settings()->remove($key);
```

### Groups

[](#groups)

From `v 1.0.6` You can organize your settings into groups. If you skip the group name it will store settings with `default` group name.

> If you are updating from previous version dont forget to run the migration

You have all above methods available just set you working group by calling `->group('group_name')` method and chain on:

```
settings()->group('team.1')->set('app_name', 'My Team App');
settings()->group('team.1')->get('app_name');
> My Team App

settings()->group('team.2')->set('app_name', 'My Team 2 App');
settings()->group('team.2')->get('app_name');
> My Team 2 App

// You can use facade
\Settings::group('team.1')->get('app_name')
> My Team App
```

### Changelog

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.

### Testing

[](#testing)

The package contains some integration/smoke tests, set up with Orchestra. The tests can be run via phpunit.

```
$ composer test
```

### Contributing

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

### Security

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

### Credits

[](#credits)

- [turki alawlqy](https://github.com/turkialawlqy)

### License

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity57

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

Total

3

Last Release

1646d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/3389371?v=4)[Turkialawlqy](/maintainers/turkialawlqy)[@turkialawlqy](https://github.com/turkialawlqy)

---

Top Contributors

[![turkialawlqy](https://avatars.githubusercontent.com/u/3389371?v=4)](https://github.com/turkialawlqy "turkialawlqy (3 commits)")

---

Tags

laraveleloquentdatabase settingsdb settingsTurki

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/turkialawlqy-laravel-settings/health.svg)

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

###  Alternatives

[qcod/laravel-app-settings

A package with UI to store and manage all the settings for your application

34197.3k](/packages/qcod-laravel-app-settings)[qcod/laravel-settings

Store key value pair in database as settings

230196.6k3](/packages/qcod-laravel-settings)[anourvalar/eloquent-serialize

Laravel Query Builder (Eloquent) serialization

11320.2M21](/packages/anourvalar-eloquent-serialize)[bavix/laravel-clickhouse

Eloquent model for ClickHouse

72214.1k2](/packages/bavix-laravel-clickhouse)[stayallive/laravel-eloquent-observable

Register Eloquent model event listeners just-in-time directly from the model.

2928.9k7](/packages/stayallive-laravel-eloquent-observable)

PHPackages © 2026

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