A modern, secure, and feature-rich PHP file manager with beautiful Bulma UI. Built for standalone use or seamless integration with frameworks like CodeIgniter 4.
π€ Built with Antigravity - This project was developed using AI-assisted coding.
- π Browse & Navigate - Intuitive directory browsing with breadcrumb navigation
- β¬οΈ Upload Files - Drag-and-drop file uploads with progress indicators
- π₯ Download - Single file or multi-file download as ZIP
- βοΈ Rename - Quick inline renaming
- ποΈ Delete - Single or bulk delete with confirmation modal
- π Copy & Paste - Clipboard operations with cut/copy/paste
- π¦ Compress - Create ZIP archives from selected files
- βοΈ Checkbox Selection - Select multiple files with checkboxes
- π±οΈ Shift+Click - Range selection like native file managers
- β¨οΈ Ctrl/Cmd+Click - Add/remove from selection
- π― Select All - Quick select/deselect all items
- π§ Bulk Actions - Cut, copy, delete, download selected files
- π― Drag to Move - Drag files/folders into other folders
- π¨ Visual Feedback - Drop targets highlight during drag
- π¦ Multi-Drag - Select multiple items and drag them together
- β Confirmation Modal - Preview move operation before confirming
- πΌοΈ Image Preview - View images with dimensions
- π Text/Code View - Syntax-highlighted code preview
- π PDF Viewer - Inline PDF viewing
- π HEIC Support - Apple HEIC/HEIF image preview and dimensions
- π Authentication - Built-in login with password hashing
- π‘οΈ CSRF Protection - Token-based form protection
- π Path Validation - Prevents directory traversal attacks
- βοΈ Configurable Auth Bypass - Optional for framework integration
- π¨ Bulma CSS - Clean, responsive design
- π Context Menu - Right-click actions
- π Toast Notifications - Non-intrusive feedback
- π± Responsive - Works on desktop and mobile
composer require lifeishex/php-file-manager- Clone or download the repository
- Copy files to your project
- Configure
config.php
Create or modify config.php:
<?php
return [
'fm' => [
'root_path' => '/path/to/managed/files',
'title' => 'File Manager',
'language' => 'en',
'date_format' => 'Y-m-d H:i',
'show_hidden' => false,
],
'auth' => [
'require_login' => true,
'username' => 'admin',
'password' => password_hash('your-password', PASSWORD_DEFAULT),
],
'upload' => [
'max_file_size' => 50 * 1024 * 1024, // 50MB
'chunk_size' => 1 * 1024 * 1024, // 1MB chunks
'allowed_extensions' => ['*'], // All extensions
],
'security' => [
'csrf_enabled' => true,
],
];<?php
require_once 'vendor/autoload.php';
use FileManager\FileManager;
$config = require 'config.php';
$fileManager = new FileManager($config);
$fileManager->run();<?php
// app/Controllers/FileManagerController.php
namespace App\Controllers;
use FileManager\Integration\FileManagerService;
class FileManagerController extends BaseController
{
public function index()
{
$config = [
'fm' => [
'root_path' => WRITEPATH . 'uploads',
'asset_path' => '/filemanager/assets',
],
'auth' => [
'require_login' => false, // Use CI4's auth
],
];
$fileManager = new FileManagerService($config);
return $fileManager->handleRequest();
}
}// Per-user file management
$config['fm']['root_path'] = WRITEPATH . 'uploads/user_' . session()->get('user_id');- PHP 8.3+
- ext-zip - For multi-file ZIP downloads
- ext-mbstring - For proper string handling
- sips (macOS) or ImageMagick - For HEIC image support
Contributions are welcome! This is an MIT-licensed open-source project.
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
Mahdi Hezaveh
- GitHub: @LifeIsHex
If you find this project useful, please consider giving it a β on GitHub! Your support helps the project grow and motivates continued development.












