Easy Thumbnails generates scaled and cropped image derivatives for Django sites. It supports predefined aliases, template tags, Python helpers, and optional SVG handling via an emulation layer.
Overview
Easy Thumbnails is a Django application for creating and serving thumbnail images from uploaded or stored files. It targets Django 4.2 and later and integrates through INSTALLED_APPS and a database migration.
Thumbnail sizes and behaviors can be defined in THUMBNAIL_ALIASES settings or passed per call in templates and Python. The thumbnail template tag and get_thumbnailer API return URLs for generated files. ThumbnailerImageField and ThumbnailerField tie aliases directly to model fields.
Processors handle options such as crop (including smart crop and edge offsets), JPEG quality, upscale, and ICC profile retention. An optional svg extra adds a vector image layer that mimics PIL behavior so SVG uploads can flow through the same scaling and cropping pipeline as raster formats.
A separate easythumbnails_tags module avoids clashing with other libraries that also register a thumbnail template tag. Documentation covers installation, aliases, model fields, processors, and WebP-related extensions.
Key features
- Predefined THUMBNAIL_ALIASES
- Template thumbnail tag
- Python get_thumbnailer API
- ThumbnailerImageField model fields
- Smart and manual crop options
- Configurable JPEG quality
- Optional SVG thumbnailing extra
- Pluggable thumbnail processors
Use cases
- Avatar and profile photo sizes
- CMS image variants in templates
- Consistent crop presets sitewide
- Serving SVG like raster uploads
- Model-linked thumbnail aliases