A modern, beautiful web interface for ImageMagick with AI-powered features
Features β’ Quick Start β’ Configuration β’ Documentation β’ Contributing
imagemagick.mp4
- Resize & Crop - Precise dimensions, percentage scaling, aspect ratio lock
- Format Conversion - WebP, AVIF, JPEG, PNG, GIF, TIFF, PDF support
- Filters & Effects - Blur, Sharpen, Grayscale, Sepia, Brightness, Contrast, Saturation
- Watermark & Text - Custom text overlays with position, opacity, and font size control
- Rotate & Flip - 90Β°, 180Β°, 270Β° rotation with horizontal/vertical flip
- Batch Processing - Process multiple images simultaneously
- Background Removal - One-click AI background removal using rembg
- Auto Enhance - Automatic image enhancement (normalize, saturation, sharpening)
- Smart Upscaling - 2x/4x resolution upscaling with LANCZOS algorithm
- Notion-inspired Design - Ultra-clean, minimalist white interface
- Real-time Preview - See changes before applying
- Drag & Drop Upload - Easy multi-file upload
- Image Editor - Full-featured editor with live preview
- Terminal Mode - Direct ImageMagick command input for power users
- Dark/Light Mode - Automatic or manual theme switching
- PWA Support - Install as desktop/mobile app
- Docker Ready - One command deployment
- Type-Safe - Full TypeScript + Pydantic validation
- Secure - Command whitelist, timeouts, resource limits
- Queue System - Redis-based job queue for heavy operations
- History - Track all processed images with re-download option
mkdir imagemagick-webgui && cd imagemagick-webgui
curl -O https://raw.githubusercontent.com/PrzemekSkw/imagemagick-webui/main/docker-compose.example.yml
mv docker-compose.example.yml docker-compose.yml
docker compose up -dAccess: http://localhost:3000
π Need custom ports, authentication, or reverse proxy? See Installation Guide
β οΈ Production: ChangeSECRET_KEYandJWT_SECRETin docker-compose.yml before deploying!
| Service | Port | Description |
|---|---|---|
| Frontend | 3000 | Next.js web interface |
| Backend | 8000 | FastAPI REST API |
| PostgreSQL | 5432 | Database (internal) |
| Redis | 6379 | Queue system (internal) |
Once running, access the interactive API docs:
- Swagger UI: http://localhost:8000/docs
- ReDoc: http://localhost:8000/redoc
βββββββββββββββββββ βββββββββββββββββββ
β Next.js 15 ββββββΆβ FastAPI β
β (Frontend) β β (Backend) β
β Port: 3000 β β Port: 8000 β
βββββββββββββββββββ ββββββββββ¬βββββββββ
β
ββββββββββββββ΄βββββββββββββ
β β
βββββββΌββββββ βββββββββΌββββββββ
β PostgreSQLβ β Redis β
β (DB) β β (Queue) β
β Port: 5432β β Port: 6379 β
βββββββββββββ βββββββββββββββββ
β
βββββββββΌββββββββ
β RQ Worker β
β (Background) β
βββββββββββββββββ
| Operation | Parameters | Example |
|---|---|---|
resize |
width, height, percent, fit |
{"width": 800, "height": 600} |
crop |
x, y, width, height |
{"x": 0, "y": 0, "width": 500, "height": 500} |
rotate |
degrees |
{"degrees": 90} |
flip |
direction |
{"direction": "horizontal"} |
blur |
sigma |
{"sigma": 10} |
sharpen |
sigma |
{"sigma": 2} |
brightness |
value |
{"value": 120} |
contrast |
value |
{"value": 110} |
saturation |
value |
{"value": 130} |
grayscale |
- | {} |
sepia-tone |
threshold |
{"threshold": 80} |
watermark |
text, position, font_size, opacity |
{"text": "Β©2024", "position": "southeast"} |
format |
format, quality |
{"format": "webp", "quality": 85} |
For advanced users, use Terminal Mode to run raw ImageMagick commands:
# Convert to WebP with quality
magick input.jpg -quality 80 output.webp
# Create thumbnail
magick input.jpg -thumbnail 300x300 output.jpg
# Add border
magick input.jpg -border 10x10 -bordercolor "#ff0000" output.jpg
# Composite images
magick base.jpg overlay.png -composite output.jpgBackend:
cd backend
python -m venv venv
source venv/bin/activate # Windows: venv\Scripts\activate
pip install -r requirements.txt
uvicorn app.main:app --reload --port 8000Frontend:
cd frontend
npm install
npm run dev# Backend tests
cd backend
pytest
# Frontend tests
cd frontend
npm testimagemagick-webui/
βββ backend/
β βββ app/
β β βββ api/ # API endpoints
β β βββ core/ # Config, security, database
β β βββ models/ # SQLAlchemy models
β β βββ services/ # Business logic
β β βββ workers/ # Background tasks
β βββ tests/
β βββ requirements.txt
βββ frontend/
β βββ app/ # Next.js App Router pages
β βββ components/ # React components
β β βββ features/ # Feature components
β β βββ layout/ # Layout components
β β βββ ui/ # UI primitives (shadcn/ui)
β βββ lib/ # Utilities, API client, store
βββ docker-compose.yml
βββ Dockerfile
βββ README.md
- Command Whitelist - Only allowed ImageMagick operations
- Input Validation - Pydantic models for all inputs
- Resource Limits - Memory (2GB), timeout (300s), disk limits
- File Validation - MIME type and extension checking
- Rate Limiting - Configurable request limits
- Non-root Container - Runs as unprivileged user
Contributions are welcome! Please read our Contributing Guide for details.
- 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.
If you find this project useful, please consider supporting its development:
Your support helps maintain and improve this project. Thank you! β€οΈ
- ImageMagick - The powerful image processing library
- rembg - AI background removal
- Next.js - React framework
- FastAPI - Python web framework
- shadcn/ui - Beautiful UI components
- Tailwind CSS - Utility-first CSS
Made with β€οΈ by PrzemekSkw