PHPackages                             zarulizham/laravel-database-backup-scheduler - 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. [File &amp; Storage](/categories/file-storage)
4. /
5. zarulizham/laravel-database-backup-scheduler

ActiveLibrary[File &amp; Storage](/categories/file-storage)

zarulizham/laravel-database-backup-scheduler
============================================

Automate and schedule your Laravel application database to your preferred storage filesystem

1.0.3(1y ago)0636MITPHPPHP ^8.2

Since Aug 22Pushed 1y ago1 watchersCompare

[ Source](https://github.com/zarulizham/laravel-database-backup-scheduler)[ Packagist](https://packagist.org/packages/zarulizham/laravel-database-backup-scheduler)[ Docs](https://github.com/zarulizham/laravel-database-backup-scheduler)[ GitHub Sponsors](https://github.com/ZarulIzham)[ RSS](/packages/zarulizham-laravel-database-backup-scheduler/feed)WikiDiscussions main Synced 3w ago

READMEChangelog (2)Dependencies (10)Versions (5)Used By (0)

Automate and schedule your Laravel application database to your preferred storage filesystem
============================================================================================

[](#automate-and-schedule-your-laravel-application-database-to-your-preferred-storage-filesystem)

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

[](#installation)

You can install the package via composer:

```
composer require zarulizham/laravel-database-backup-scheduler
```

You can publish and run the migrations with:

```
php artisan vendor:publish --tag="database-backup-scheduler-migrations"
php artisan migrate
```

This package relies on `spatie/media-library`. If your project did not use `spatie/media-library` package, publish its migration and/or config file.

```
php artisan vendor:publish --tag="medialibrary-config"
php artisan vendor:publish --tag="medialibrary-migrations"
php artisan migrate
```

You can publish the config file with:

```
php artisan vendor:publish --tag="database-backup-scheduler-config"
```

To custom location of backup path, refer [Spatie documentation](https://spatie.be/docs/laravel-medialibrary/v11/advanced-usage/using-a-custom-directory-structure)

This is the contents of the published config file. You may modify as per your needs.

```
return [
    'connections' => [
        'mysql' => [
            'excludeTables' => [],
            'storage' => env('FILESYSTEM_DISK', 'local'),
        ],
    ],
];
```

Usage
-----

[](#usage)

Place these two scheduler in `app/Console/Kernel.php` (&lt;= Laravel 10) or `routes/console.php` (&gt;= Laravel 11)

```
$schedule->command('db:backup')->dailyAt('00:00')
    ->environments('production');

$schedule->command('db:backup:prune')->dailyAt('00:00')
    ->environments('production');
```

To specify custom retention days for backup, specify `--days` option on `db:backup:prune` command. Default 14 days.

Security Vulnerabilities
------------------------

[](#security-vulnerabilities)

Please review [our security policy](../../security/policy) on how to report security vulnerabilities.

Credits
-------

[](#credits)

- [Zarul Zubir](https://github.com/zarulizham)
- [All Contributors](../../contributors)

###  Health Score

30

—

LowBetter than 62% of packages

Maintenance33

Infrequent updates — may be unmaintained

Popularity13

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity55

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

Total

4

Last Release

668d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/ae2768e1d22dfc2cf76094e1bd66c4a156fea41873eada5277bea89d709bd93b?d=identicon)[zarulizham](/maintainers/zarulizham)

---

Top Contributors

[![zarulizham](https://avatars.githubusercontent.com/u/10229855?v=4)](https://github.com/zarulizham "zarulizham (5 commits)")

---

Tags

laravelzarulizhamlaravel-database-backup-scheduler

###  Code Quality

TestsPest

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/zarulizham-laravel-database-backup-scheduler/health.svg)

```
[![Health](https://phpackages.com/badges/zarulizham-laravel-database-backup-scheduler/health.svg)](https://phpackages.com/packages/zarulizham-laravel-database-backup-scheduler)
```

###  Alternatives

[spatie/laravel-pdf

Create PDFs in Laravel apps

1.0k4.3M42](/packages/spatie-laravel-pdf)[spatie/laravel-health

Monitor the health of a Laravel application

87411.3M153](/packages/spatie-laravel-health)[rawilk/profile-filament-plugin

Profile &amp; MFA starter kit for filament.

3913.7k](/packages/rawilk-profile-filament-plugin)[harris21/laravel-fuse

Circuit breaker for Laravel queue jobs. Protect your workers from cascading failures.

43140.3k](/packages/harris21-laravel-fuse)[vormkracht10/laravel-mails

Laravel Mails can collect everything you might want to track about the mails that has been sent by your Laravel app.

24855.3k](/packages/vormkracht10-laravel-mails)[tapp/filament-form-builder

User facing form builder using Filament components

141.9k2](/packages/tapp-filament-form-builder)

PHPackages © 2026

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