# File Browser Web Interface

> Web-based file manager with sharing and user management.

- Category: Productivity & Collaboration
- Difficulty: beginner
- Components: filebrowser, nginx
- Tags: filebrowser, files, sharing, web, manager
- Source: https://docker.recipes/productivity/filebrowser-complete

## Overview

File Browser is an open-source web-based file manager written in Go that transforms any server directory into a feature-rich web interface. Created by Henrique Dias, it provides a modern alternative to traditional FTP or SFTP access, offering file uploads, downloads, editing, sharing, and user management through a clean web interface. The application supports multiple authentication backends, custom themes, and command execution, making it a powerful tool for both personal and enterprise file management scenarios.

This stack combines File Browser with NGINX to create a production-ready file management solution. File Browser handles the core functionality of file operations, user authentication, and web interface rendering, while NGINX serves as a reverse proxy providing SSL termination, request routing, and static asset optimization. NGINX's high-performance architecture ensures the file management interface remains responsive even under heavy load, while its caching capabilities reduce server strain during frequent file downloads.

This combination is ideal for system administrators managing shared storage, development teams needing collaborative file access, and organizations requiring secure file sharing without cloud dependencies. The NGINX frontend allows for advanced configurations like custom domains, SSL certificates, rate limiting, and integration with existing web infrastructure, making File Browser suitable for enterprise deployments while maintaining the simplicity needed for home lab environments.

## Features

- Multi-user authentication with granular permission controls per directory and file operation
- Real-time file editing with syntax highlighting for code files and documents
- Secure file sharing via time-limited or password-protected download links
- Command execution interface allowing custom scripts and system commands through web UI
- Built-in image gallery with thumbnail generation and slideshow capabilities
- NGINX reverse proxy with SSL termination and custom domain support
- Advanced search functionality with file content indexing and filtering
- Mobile-responsive interface optimized for file management on tablets and smartphones

## Use cases

- Small business shared storage with employee access controls and file versioning
- Development team collaboration with Git repository browsing and code editing capabilities
- Media server management for organizing and sharing photos, videos, and documents
- Remote server administration providing web-based access to system files and logs
- Educational institution file sharing for students and faculty with permission-based access
- Home lab file management replacing traditional NAS interfaces with modern web UI
- Client file delivery system for agencies sharing large design files and project assets

## Prerequisites

- Docker Engine 20.10+ and Docker Compose V2 for container orchestration
- Minimum 512MB RAM (1GB recommended) for File Browser and NGINX containers
- Available ports 80 and 8080, or alternative ports configured in firewall
- File system with appropriate permissions for PUID/PGID 1000 user access
- Basic understanding of NGINX configuration for SSL setup and custom domains
- Valid SSL certificates if deploying with HTTPS in production environment

## docker-compose.yml

```yaml
services:
  filebrowser:
    image: filebrowser/filebrowser:latest
    ports:
      - "8080:80"
    volumes:
      - /path/to/files:/srv
      - filebrowser_db:/database
      - ./filebrowser.json:/.filebrowser.json
    environment:
      - PUID=1000
      - PGID=1000
    networks:
      - files_net

  nginx:
    image: nginx:alpine
    ports:
      - "80:80"
    volumes:
      - ./nginx.conf:/etc/nginx/nginx.conf:ro
    depends_on:
      - filebrowser
    profiles:
      - production
    networks:
      - files_net

volumes:
  filebrowser_db:

networks:
  files_net:
```

## .env

```bash
# File Browser
# Update /path/to/files to your directory
# File Browser at http://localhost:8080
# Default: admin / admin
```

## Usage notes

- File Browser at http://localhost:8080
- Default credentials: admin/admin
- Set /srv to your file directory
- User management with permissions
- Share files with links

## Troubleshooting

- Permission denied errors on file operations: Ensure host directory ownership matches PUID/PGID 1000 or update environment variables
- File Browser shows 'Database locked' error: Stop containers, remove filebrowser_db volume, and restart to reset database
- NGINX 502 Bad Gateway errors: Verify filebrowser container is healthy and network connectivity between containers exists
- Upload failures for large files: Increase NGINX client_max_body_size directive and check available disk space
- Users cannot access shared directories: Check File Browser user permissions and ensure shared paths exist in container filesystem
- File Browser interface loads slowly: Configure NGINX caching for static assets and enable gzip compression

