Deploy imgproxy
Fast image server: resize, crop and convert images on the fly by URL
Just deployed
Deploy and Host imgproxy on Railway
imgproxy is a fast, open-source image server. It resizes, crops, rotates, watermarks and converts images on the fly from a URL, using libvips, and serves modern formats like WebP and AVIF. Your app links to imgproxy instead of storing many sizes of each image, and imgproxy fetches the original and processes it per request.
About Hosting imgproxy
imgproxy is a single stateless service: it stores nothing, so it needs no database or volume. This template builds imgproxy v4.0.24 from the official image, pinned by digest, in a GitHub repo that delivers future updates. It listens on Railway's PORT, gets a public domain and a health check on /health, and generates a hex IMGPROXY_KEY and IMGPROXY_SALT so every image URL must be signed. Without them the container refuses to start, so it never runs as an open proxy. Copy the key and salt into your app, sign URLs with them, and point it at your Railway domain. Put a CDN in front for heavy traffic.
Common Use Cases
- Serve responsive thumbnails and resized images for a website or app without pre-generating sizes
- Convert uploads to WebP or AVIF on the fly to cut page weight
- Crop, watermark or blur images from S3-compatible storage or any public URL
Dependencies for imgproxy Hosting
- None: imgproxy runs as one service with no database or volume
- Optional: S3-compatible storage (or any HTTP origin) holding your source images
Deployment Dependencies
- imgproxy docs: https://docs.imgproxy.net/
- Signing URLs: https://docs.imgproxy.net/usage/signing_url
- Configuration options: https://docs.imgproxy.net/configuration/options
- Release v4.0.24: https://github.com/imgproxy/imgproxy/releases/tag/v4.0.24
- Template source: https://github.com/aalfath/imgproxy-railway-template
Implementation Details
A signed URL looks like https://YOUR-DOMAIN/SIGNATURE/rs:fit:300:300/plain/https://example.com/photo.jpg@webp, where the signature is the URL-safe Base64 of HMAC-SHA256(key, salt + path), without padding. The imgproxy repo has signing examples for most languages. Optional settings go in as service variables: IMGPROXY_ALLOWED_SOURCES to fetch only from your own origins, IMGPROXY_USE_S3 with the AWS_* variables to read from S3 buckets, and IMGPROXY_MAX_SRC_RESOLUTION to limit source size. Baked-in defaults: ETag and Last-Modified support, automatic WebP for browsers that accept it, and a one-year cache TTL.
Why Deploy imgproxy on Railway?
Railway is a singular platform to deploy your infrastructure stack. Railway will host your infrastructure so you don't have to deal with configuration, while allowing you to vertically and horizontally scale it.
By deploying imgproxy on Railway, you are one step closer to supporting a complete full-stack application with minimal burden. Host your servers, databases, AI agents, and more on Railway.
Template Content
