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)0636↓100%MITPHPPHP ^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 1mo 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

31

—

LowBetter than 68% of packages

Maintenance34

Infrequent updates — may be unmaintained

Popularity16

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

623d 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/livewire-filepond

Upload files using Filepond in Livewire components

306452.7k3](/packages/spatie-livewire-filepond)[elegantly/laravel-invoices

Store invoices safely in your Laravel application

23131.8k](/packages/elegantly-laravel-invoices)[vormkracht10/laravel-mails

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

24149.7k](/packages/vormkracht10-laravel-mails)[mwguerra/filemanager

A full-featured file manager package for Laravel and Filament v5 with dual operating modes, drag-and-drop uploads, S3/MinIO support, and comprehensive security features.

718.5k1](/packages/mwguerra-filemanager)[codebar-ag/laravel-flysystem-cloudinary

Cloudinary Flysystem v1 integration with Laravel

1224.9k2](/packages/codebar-ag-laravel-flysystem-cloudinary)[mreduar/s3m

Multipart Uploads using Laravel and AWS S3

173.6k](/packages/mreduar-s3m)

PHPackages © 2026

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