PHPackages                             fomvasss/laravel-backup-ui - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. fomvasss/laravel-backup-ui

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

fomvasss/laravel-backup-ui
==========================

Web interface for spatie/laravel-backup package

1.1.0(3mo ago)1180↓16.7%MITPHPPHP ^8.0CI failing

Since Jan 18Pushed 3mo agoCompare

[ Source](https://github.com/fomvasss/laravel-backup-ui)[ Packagist](https://packagist.org/packages/fomvasss/laravel-backup-ui)[ RSS](/packages/fomvasss-laravel-backup-ui/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (5)Versions (4)Used By (0)

Laravel Backup UI
=================

[](#laravel-backup-ui)

[![Latest Version on Packagist](https://camo.githubusercontent.com/d58e554d3760caf101912e6e2a176d6b3c0a6f7b9f2e941dc9dcbc00779a40f7/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f666f6d76617373732f6c61726176656c2d6261636b75702d75692e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/fomvasss/laravel-backup-ui)[![Total Downloads](https://camo.githubusercontent.com/cdcfa2827d39f1f752199c6d0ebafe83fe23d45278c119fac162c3c428a5e7de/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f666f6d76617373732f6c61726176656c2d6261636b75702d75692e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/fomvasss/laravel-backup-ui)

A beautiful web interface for managing [spatie/laravel-backup](https://github.com/spatie/laravel-backup) package. Built with Bootstrap 5 and designed to be easily integrated into any Laravel admin panel.

Features
--------

[](#features)

- 🎨 Modern Bootstrap 5 UI
- 📊 Backup status monitoring
- 🔄 Create backups (full, database-only, files-only)
- 📥 Download backup files
- 🗑️ Delete individual backups
- 🧹 Clean old backups
- 🔐 Flexible authentication system
- 📱 Responsive design
- ⚡ Real-time status updates

Screenshots
-----------

[](#screenshots)

[![Backup Management Interface](screenshot.jpg)](screenshot.jpg)

Requirements
------------

[](#requirements)

- PHP ^8.0
- Laravel ^9.0|^10.0|^11.0|^12.0
- spatie/laravel-backup ^8.0|^9.0

Version Compatibility
---------------------

[](#version-compatibility)

This package supports both major versions of spatie/laravel-backup and multiple Laravel versions:

- **spatie/laravel-backup v8.x**: Full compatibility with existing API
- **spatie/laravel-backup v9.x**: Automatic adaptation to new API structure
- **Laravel 9.x, 10.x, 11.x, 12.x**: Full framework compatibility

The package automatically detects the installed version and adapts accordingly:

- Command signatures are handled for both versions
- API changes in BackupDestinationStatusFactory are automatically managed
- Storage calculation methods work with both versions
- Error handling is improved for both versions

For detailed Laravel v12 compatibility information, see [LARAVEL-V12-COMPATIBILITY.md](LARAVEL-V12-COMPATIBILITY.md).

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

[](#installation)

You can install the package via composer:

```
composer require fomvasss/laravel-backup-ui
```

Publish the configuration file:

```
php artisan vendor:publish --tag=backup-ui-config
```

Optionally, you can publish the views:

```
php artisan vendor:publish --tag=backup-ui-views
```

Configuration
-------------

[](#configuration)

The configuration file `config/backup-ui.php` allows you to customize the package:

```
return [
    // Route prefix for the backup UI
    'route_prefix' => 'backup',

    // Middleware to apply to routes
    'middleware' => ['web', 'auth'],

    // Page title
    'page_title' => 'Backup Management',

    // Number of backups per page
    'per_page' => 15,

    // Specific users allowed to access (empty = all authenticated users)
    'allowed_users' => [
        // 'admin@example.com'
    ],

    // Custom authorization callback
    'auth_callback' => null,
];
```

Troubleshooting
---------------

[](#troubleshooting)

### "mysqldump: not found" Error

[](#mysqldump-not-found-error)

If you encounter the error `sh: 1: mysqldump: not found` when creating backups through the web interface, this is because the web server doesn't have the same PATH as your console.

**Solutions:**

1. **Install MySQL client tools on your server:**

    ```
    # Ubuntu/Debian
    sudo apt-get install default-mysql-client

    # CentOS/RHEL
    sudo yum install mysql

    # For Laradock users
    docker exec laradock_php-fpm_1 apt-get update
    docker exec laradock_php-fpm_1 apt-get install -y default-mysql-client
    ```
2. **Set environment PATH in your web server configuration:**

    ```
    # Apache
    SetEnv PATH "/usr/local/bin:/usr/bin:/bin"
    ```

    ```
    # Nginx + PHP-FPM
    # Add to pool configuration
    env[PATH] = /usr/local/bin:/usr/bin:/bin
    ```

The mysqldump tool should be properly configured at the server level, not at the application level.

### "Backup file not found" when downloading

[](#backup-file-not-found-when-downloading)

If existing backups show in the list but fail to download with "Backup file not found", this is because spatie/laravel-backup stores files in date-organized subdirectories.

**The package automatically handles this by:**

- Searching for files in spatie's date-based directory structure (`backup-name/YYYY/MM/DD/file.zip`)
- Looking through all subdirectories for matching filenames
- Supporting files with special characters in names

**For debugging, check Laravel logs for detailed file search information.**

### External Disk Support (S3, FTP, Google Cloud, etc.)

[](#external-disk-support-s3-ftp-google-cloud-etc)

The package fully supports external backup disks including:

- **Amazon S3** (`s3`)
- **Google Cloud Storage** (`gcs`, `google`)
- **FTP/SFTP** (`ftp`, `sftp`)
- **Dropbox** (`dropbox`)
- **Other Laravel filesystem drivers**

**Key features for external disks:**

- Automatic driver detection and optimization
- Intelligent reachability checking for each disk type
- Graceful handling of network timeouts and connection issues
- Proper streaming for large backup file downloads
- Error logging for troubleshooting remote disk issues

**Configuration example for S3:**

```
// config/filesystems.php
'disks' => [
    's3-backups' => [
        'driver' => 's3',
        'key' => env('AWS_ACCESS_KEY_ID'),
        'secret' => env('AWS_SECRET_ACCESS_KEY'),
        'region' => env('AWS_DEFAULT_REGION'),
        'bucket' => env('AWS_BUCKET'),
        'url' => env('AWS_URL'),
        'endpoint' => env('AWS_ENDPOINT'),
    ],
],

// config/backup.php
'backup' => [
    'destination' => [
        'disks' => ['s3-backups'],
    ],
],
```

**Configuration example for FTP:**

```
// config/filesystems.php
'disks' => [
    'ftp-backups' => [
        'driver' => 'ftp',
        'host' => env('FTP_HOST'),
        'username' => env('FTP_USERNAME'),
        'password' => env('FTP_PASSWORD'),
        'port' => env('FTP_PORT', 21),
        'root' => env('FTP_ROOT', '/backups'),
        'passive' => true,
        'ssl' => false,
        'timeout' => 30,
    ],
],
```

**Note:** For external disks, file operations (download/delete) may take longer due to network latency. The interface will show appropriate loading states.

Usage
-----

[](#usage)

After installation, the backup interface will be available at `/admin/backup` (or your configured route prefix).

### Basic Usage

[](#basic-usage)

1. **View Backups**: Navigate to the backup UI to see all configured backup destinations and existing backups
2. **Create Backup**: Use the "Create Backup" dropdown to create full, database-only, or files-only backups
3. **Download**: Click the download button next to any backup to download it
4. **Delete**: Click the trash icon to delete individual backups
5. **Clean**: Use the "Clean Old" button to remove old backups according to your retention policy

### Custom Authentication

[](#custom-authentication)

You can implement custom authentication by setting the `auth_callback` in the configuration:

```
// config/backup-ui.php
'auth_callback' => function () {
    return auth()->check() && auth()->user()->hasRole('admin');
},
```

### Restricting Access to Specific Users

[](#restricting-access-to-specific-users)

```
// config/backup-ui.php
'allowed_users' => [
    'admin@yoursite.com',
    'backups@yoursite.com',
],
```

### Integration with Admin Panels

[](#integration-with-admin-panels)

The package is designed to be easily integrated into existing admin panels:

#### Laravel Nova

[](#laravel-nova)

```
// In your Nova dashboard
Menu::make('Backup Management', '/admin/backup')
    ->icon('database')
    ->external();
```

#### Filament

[](#filament)

```
// In your Filament panel
NavigationItem::make('Backups')
    ->url('/admin/backup')
    ->icon('heroicon-o-circle-stack')
    ->external();
```

#### Custom Admin Panel

[](#custom-admin-panel)

Simply add a link to `/admin/backup` in your admin navigation menu.

Customization
-------------

[](#customization)

### Views

[](#views)

If you need to customize the views, publish them first:

```
php artisan vendor:publish --tag=backup-ui-views
```

The views will be published to `resources/views/vendor/backup-ui/`.

### Styling

[](#styling)

The package uses Bootstrap 5 classes. You can override styles by publishing the views and modifying the CSS, or by including your own CSS after the Bootstrap CSS.

Security
--------

[](#security)

The package includes several security measures:

- Authentication middleware (configurable)
- User restriction capabilities
- CSRF protection on all forms
- File existence validation before downloads
- Path traversal protection

Contributing
------------

[](#contributing)

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

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

[](#security-vulnerabilities)

If you discover a security vulnerability within this package, please send an e-mail to the author via email. All security vulnerabilities will be promptly addressed.

Credits
-------

[](#credits)

- [fomvasss](https://github.com/fomvasss)
- Built on top of [spatie/laravel-backup](https://github.com/spatie/laravel-backup)

License
-------

[](#license)

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

Support
-------

[](#support)

If you find this package helpful, please consider starring the repository and sharing it with others!

###  Health Score

38

—

LowBetter than 85% of packages

Maintenance80

Actively maintained with recent releases

Popularity16

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity41

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

Total

3

Last Release

105d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/4f99b460639e7d6871597882226b1e0d9e3055992eac8b22bfcd4f90fbdac95c?d=identicon)[fomvasss](/maintainers/fomvasss)

---

Top Contributors

[![fomvasss](https://avatars.githubusercontent.com/u/19834478?v=4)](https://github.com/fomvasss "fomvasss (2 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/fomvasss-laravel-backup-ui/health.svg)

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

###  Alternatives

[wireui/wireui

TallStack components

1.8k1.3M16](/packages/wireui-wireui)[livewire/volt

An elegantly crafted functional API for Laravel Livewire.

4195.3M84](/packages/livewire-volt)[ramonrietdijk/livewire-tables

Dynamic tables for models with Laravel Livewire

21147.4k](/packages/ramonrietdijk-livewire-tables)

PHPackages © 2026

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