Image Resizer - the IIS/ASP.NET module for everyone

Resize, watermark, crop, rotate and filter from the image URL.
Usable from javascript, css, html, php, ruby, python, asp, asp.net, anything!

Frequently asked questions

If you're getting an error message, see the troubleshooting page instead.

Q: Is it possible to specify the width and height, and have your image resized and cropped to fit the aspect ratio, losing as little image area as possible?
A: Yes, and it is easy. Use ?width=x&height=y&mode=crop.
Q: Are multi-page .TIFFs supported?
A: Yes - you can convert any page of a multi-page .TIFF to .jpg, .png, or .gif. Use ?page=x&format=jpg
Q: Can I resize the same image to different sizes?
A: Yes - there is no limit on how many sizes of an image can be created.
Q: Is load balancing across multiple servers supported?
A: Yes, and all plugins support web farms, web gardens, and load balancing.
Q: Do the image names change when they are resized? Is SEO affected?
A: No, image names are retained - SEO isn't affected.
Q: If I resize a photo to its original size, will a new photo be returned, or the original?
A: All photos are re-compressed, even if the original photo is the same size. This allows ICC correction, file size improvement, and metadata removal.
Q: Can the resizer both crop, then resize at the same time?
A: Yes, you can specify a crop rectangle with ?crop=(x1,y1,x2,y2) or ?mode=crop, and add &width=x or any of the resizing commands to resizing the resulting crop. All commands can be combined.
Q: Can I use this on images not located on the server?
A: Yes, with RemoteReader (Any HTTP server), S3Reader (Amazon S3 blobs), AzureReader (Azure blobs), MongoReader (GridFS) or SqlReader (SQL blobs).
Q: When I resize a small image to larger dimensions, it stays at the original size.
A: This is by design - add &scale=both to allow images to be upscaled. You might want to consider up-scaling client-side to save bandwidth... Just set both width and height on the <img> tag. If you just want padding, use &scale=canvas
Q: Can I use this with images stored in a database?
A: Sure, with the SqlReader plugin.
Q: Can I use this to resize images as users upload them?
A: Sure! I suggest keeping the original images around, and using the resizer normally (in case you later want larger images). However, it's easy to [resize during upload](/docs/howto/upload-and-resize).
Q: Is in necessary to wildcard map everything to ASP.NET when using IIS6?
A: No - you can map .jpg, .png, and .gif individually, but you need to follow this KB article to prevent issues.
Q: I asked my hosting company to add the wildcard mapping, but images don't resize when I add ?width=x; they appear in their original size. I've verified that the HttpModule entry is in Web.Config
A: The tech support person didn't add the wildcard mapping correctly. If you can't access /resizer.debug, but you can get to /resizer.debug.ashx, it's not possible that wildcard mapping is enabled. image requests never reach asp.net. Add to your web.config temporarily (never leave it in long on a production site - slows things down). Visit mysite.com/anyimage.jpg Visit mysite.com/trace.axd. If the JPG URL isn't in here, it is impossible that the wildcard mapping is installed correctly.
Q: I'm getting OutOfMemory exceptions when I try to resize certain large images for the first time (subsequent requests are fine). They're only 15MB in jpeg form, and I have 100MB of free RAM.
A: A 15MB JPG uncompresses to about 80MB in bitmap form (depending upon the compression level). If you are resizing to a 2MB jpeg (15MB BMP), memory requirements for the operation are roughly 110MB (15 + 80 + 15). If you plan on using the resizer for very high-resolution photos (above 8MP), I suggest making sure you have ample amounts of RAM. 400MB to 1GB is usually plenty for the average web site with disk caching enabled.