FilePi is a lightweight network file browser designed primarily for Raspberry Pi and other resource-constrained devices. It allows you to browse, stream, and manage files on your device from any web browser or through the dedicated Pi View mobile app.
- π File browsing with sorting and pagination
- π¬ Video streaming support with thumbnails
- π File search functionality
- π€ File upload capabilities
- π± Compatible with Pi View mobile app
- FFmpeg (required for video thumbnail generation)
sudo apt update
sudo apt install ffmpeg
brew install ffmpeg
# Set the root directory for file browsing
export FILE_PI_ROOT_DIR=/path/to/your/files
# Optional: Set log level (DEBUG, INFO, WARN, ERROR)
export FILE_PI_LOGLEVEL=INFO
# Download the latest release from the releases section
./filepi
- Web interface: Open
http://[device-ip]:8080
in your browser - Mobile: Install the Pi View app and connect to your device
Endpoint | Description |
---|---|
GET /api/v1/files |
List files in a directory |
GET /api/v1/videos |
List video files (with recursive option) |
GET /api/v1/search |
Search for files by name |
GET /api/v1/file/{path} |
Serve a file for download |
GET /api/v1/stream/{path} |
Stream a video file |
GET /api/v1/thumbnail/{path} |
Get a thumbnail for a video file |
POST /api/v1/createfolder |
Create a new folder |
POST /api/v1/uploadfile |
Upload a file |
Parameter | Default | Description |
---|---|---|
FILE_PI_ROOT_DIR |
Current directory | Root directory for file browsing |
FILE_PI_LOGLEVEL |
INFO | Log level (DEBUG, INFO, WARN, ERROR) |
FilePi works seamlessly with the Pi View mobile app, which provides a user-friendly interface for browsing and streaming files from your server.
- Go version: Uses Fiber framework
fileserver.go
: Core file operationsrouter.go
: API endpoint definitionsmain.go
: Server initialization
go build -o filepi
This project is licensed under the MIT License - see the LICENSE file for details.
Contributions are welcome! Please feel free to submit a Pull Request.