Skip to main content

CacheControl

Latest Version https://github.com/psf/cachecontrol/actions/workflows/tests.yml/badge.svg

CacheControl is a port of the caching algorithms in httplib2 for use with requests session object.

It was written because httplib2’s better support for caching is often mitigated by its lack of thread safety. The same is true of requests in terms of caching.

Quickstart

import requests

from cachecontrol import CacheControl


sess = requests.session()
cached_sess = CacheControl(sess)

response = cached_sess.get('https://google.com')

If the URL contains any caching based headers, it will cache the result in a simple dictionary.

For more info, check out the docs

Metadata

Release files for CacheControl 0.15.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for CacheControl 0.15.0
File Size Uploaded Provenance Actions
cachecontrol-0.15.0.tar.gz 31.5 kB With provenance Details for cachecontrol-0.15.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for CacheControl 0.15.0
File Interpreter ABI Platform Actions
cachecontrol-0.15.0-py3-none-any.whl Python 3 none any Details for cachecontrol-0.15.0-py3-none-any.whl

Total release size: 53.9 kB

Release files / cachecontrol-0.15.0.tar.gz

Download URL cachecontrol-0.15.0.tar.gz
Size 31.5 kB
Tags Source
SHA-256 checksum
How to use checksums
52157b539eb64d85c8c793660e86cf05cf95fad7b98c8ef6846e4a0ddffdb193
BLAKE2b-256 checksum
How to use checksums
f603825d9b1cb14c5ca1ce4dec89fbb87ef87bdd5d45eb5bd96a463aa1ead457
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 16, 2026.

Transparency log

Release files / cachecontrol-0.15.0-py3-none-any.whl

Download URL cachecontrol-0.15.0-py3-none-any.whl
Size 22.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
10b7ab4387355ad9361d5b89bc0f6758e48099017be173241c4e0f20d9e1dad2
BLAKE2b-256 checksum
How to use checksums
8d4bfb590767eef526df867d79f1ebfaf737ce85365a752fa1f4cc428497da7d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 16, 2026.

Transparency log

Security for CacheControl 0.15.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for cachecontrol-0.15.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 16, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.15.0 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page