docs have a great explanation:
By default, the template system will read and compile your templates every time they need to do it. While the Django template system is pretty fast, the overhead of reading and compiling templates is possible.
A cached template loader is a loader class that you configure with a list of other loaders to be wrapped. Packed loaders are used to search for unknown patterns when they first meet. The cached loader then saves the compiled template in memory. The cached instance of the template is returned for subsequent requests to download the template.
For example, to enable template caching with file system template loaders and app_directories, you can use the following settings:
TEMPLATE_LOADERS = (
('django.template.loaders.cached.Loader', (
'django.template.loaders.filesystem.Loader',
'django.template.loaders.app_directories.Loader',
)),
)
source
share