Experience the power of imgcompress with the NEW modern Web UI. Check out the quick demo below:
Ever been frustrated by juggling multiple programs just to convert or compress images? I did too.
I'm Karim Zouine and I built imgcompress as a one-stop solution to effortlessly compress, convert, and resize your images—all inside a Docker container. No more complicated installations or worrying about privacy with online converters. Everything runs locally, secure and consistent across any system.
Stay up-to-date with the newest improvements:
- NEW: The Web UI now includes Storage Management for Cleanups Quickly manage and clean up your storage directly from the Web UI.
- NEW: PNG Processing now supports Transparency Enjoy enhanced image processing that now preserves PNG transparency.
For more details, check out the linked GitHub issues and pull requests!
-
📱 Convert iPhone HEIC Photos to JPEG:
Easily convert your iPhone's HEIC images to JPEG for smaller file sizes and universal compatibility. -
🖼️ Universal Format Conversion & Resizing:
Transform almost any photo format to JPEG and resize images effortlessly—ideal for creating thumbnails, web-optimized images, or custom sizes. -
⚙️ Customizable Output Quality:
Fine-tune the compression settings to balance image clarity and file size, ensuring your photos look great while saving space. -
🗂️ Batch & Single File Processing:
Whether you're processing one photo or an entire folder, imgcompress handles it all with ease. -
🔄 Seamless Automation & Flexible Logging:
Integrate imgcompress into your CI/CD pipelines and choose between human-readable logs or structured JSON for a smoother workflow.
If you find imgcompress valuable, please consider supporting the project (entirely optional). Your contributions help fund the infrastructure and development tools needed to build even better open source software during my free time. Thank you for your support!
🤗 My PayPal Email: [email protected]
Pull the latest image:
docker pull karimz1/imgcompress:latest
-
Launch the Web UI:
docker run --rm -p 5000:5000 karimz1/imgcompress:latest web
-
Access the Web UI:
Open your browser and go to: http://localhost:5000
-
Explore the Features:
- Drag & Drop Uploads: Simply drag your images into the browser.
- Batch Processing: Compress multiple images simultaneously.
- Real-Time Progress: Watch your images optimize live.
- Download Instantly: Retrieve your optimized images directly from the browser.
- Customizable Settings: Tweak quality and resize options effortlessly.
Single File Processing:
docker run --rm \
-v "$(pwd):/container/images" \
-v "$(pwd)/converted:/container/converted" \
karimz1/imgcompress:latest \
/container/images/example.jpg /container/converted --quality 80 --width 1920
Folder Processing:
docker run --rm \
-v "$(pwd):/container/images" \
-v "$(pwd)/converted:/container/converted" \
karimz1/imgcompress:latest \
/container/images /container/converted --quality 85 --width 800
-
📁 Local Directory Mapping:
Map your host machine’s directories into the Docker container:
- Input: Your original images.
- Output: Your optimized images.
-
⚙️ Process Parameters:
Customize your conversion with:
--quality
: Set JPEG quality (1–100, default: 85).--width
: Resize images to a desired width (optional).--debug
: Enable detailed logging.--json-output
: Generate logs in JSON format for automation workflows.
Text Output:
Starting image conversion process.
Processing directory: /container/input_folder/
Converted: /container/input_folder/photo1.jpg -> /container/output_folder/photo1.jpg (Q=80, W=800)
Converted: /container/input_folder/photo2.png -> /container/output_folder/photo2.jpg (Q=80, W=800)
Summary: 2 files processed, 0 errors.
JSON Output:
{
"status": "complete",
"conversion_results": {
"files": [
{
"file": "photo1.jpg",
"source": "/container/input_folder/photo1.jpg",
"destination": "/container/output_folder/photo1.jpg",
"original_width": 3648,
"resized_width": 800,
"is_successful": true,
"error": null
},
{
"file": "photo2.png",
"source": "/container/input_folder/photo2.png",
"destination": "/container/output_folder/photo2.jpg",
"original_width": 6000,
"resized_width": 800,
"is_successful": true,
"error": null
}
],
"file_processing_summary": {
"total_files_count": 2,
"successful_files_count": 2,
"failed_files_count": 0
}
}
}
- 🔧 CI/CD Integration:
Use the
--json-output
flag to obtain structured results for automation, it acts as a mini API.
Display all available options:
docker run --rm karimz1/imgcompress --help
Your images remain private—no uploads to third-party servers. Everything runs locally in Docker, ensuring your data stays secure and under your control.
Interested in contributing? Visit the Source Code on GitHub and feel free to fork, branch, and submit a pull request.
This project is licensed under the MIT License. See the LICENSE file for details.