$npx skillfedfor your agent

backoff

Function decoration for backoff and retry

With conditionsPyPI Python ModulesReleased Oct 2022162.8M downloads / moMITPure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — backoff-2.2.1-py3-none-any.whl
v2.2.1 · released 2022-10-05 · Python >=3.7,<4.0

Yes, if you need a lightweight, zero-dependency retry decorator for stable, well-understood use cases. The library is Production/Stable and has been battle-tested. However, the repository is archived and abandoned as of May 2024, so there will be no bug fixes or new features. Acceptable for existing projects or new projects where you do not expect to need ongoing maintenance; consider alternatives if you anticipate needing support or compatibility updates.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Requires Python 3.7 or later (3.7, 3.8, 3.9, 3.10 supported).
  • Low install friction with no runtime dependencies.
  • The package is in Production/Stable status but abandoned as of 2024-05-02, with no active maintenance.

License · maintenance · safety

MIT (permissive) — MIT license (permissive) allows use in commercial and private projects with minimal restrictions. Attribution is required but no copyleft obligations apply.

last release 2022-10-05 (1409 days) · last repo commit 2024-05-02 · 2,694 stars · archived

0 known vulnerabilities (OSV.dev, 2026-08-14) · 162,755,837 downloads/mo, #253 on PyPI

Verify before relying

pip install backoff

import backoff

@backoff.on_exception(backoff.expo, Exception, max_tries=3)
def my_function():
    return requests.get(url)
  • Whether the abandoned status and last commit in May 2024 pose a risk for your use case or Python version compatibility.
  • Whether asyncio decorator support is complete and tested for your async patterns.
Same gist for agents: .md · .json

What it is and what it does

backoff is a decorator library for wrapping functions to automatically retry them when exceptions occur or when a return value meets a given condition. It is designed for handling intermittent failures in network requests and external API calls, as well as for polling resources until content becomes available. The library supports both synchronous functions and asyncio coroutines.

You decorate a function with either `@backoff.on_exception` (to retry on a raised exception) or `@backoff.on_predicate` (to retry based on the return value). You specify a backoff strategy (exponential, fibonacci, constant, or custom), optional limits like `max_tries` or `max_time`, and optional jitter to randomize wait intervals. The decorator handles the retry loop internally, so your function code remains clean and focused on its core logic.

Use it for

  • Retry HTTP requests that fail due to transient network errors or rate limiting.
  • Poll an external API or message queue at intervals until a non-empty result is returned.
  • Wrap database connection attempts with exponential backoff to handle temporary unavailability.
  • Implement resilient async/await code that retries on timeout or connection exceptions.
  • Add jittered backoff to distributed systems to avoid thundering herd problems on recovery.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

With conditions

Yes, if you need a lightweight, zero-dependency retry decorator for stable, well-understood use cases.

The library is Production/Stable and has been battle-tested. However, the repository is archived and abandoned as of May 2024, so there will be no bug fixes or new features. Acceptable for existing projects or new projects where you do not expect to need ongoing maintenance; consider alternatives if you anticipate needing support or compatibility updates.

Install

backoff on PyPI

Before you install

Low install friction with no runtime dependencies. The package is in Production/Stable status but abandoned as of 2024-05-02, with no active maintenance. The repository is archived. For stable, well-tested retry logic this is acceptable; for ongoing support or bug fixes, consider alternatives.

Requires Python 3.7 or later (3.7, 3.8, 3.9, 3.10 supported).

License in practice

MIT license (permissive) allows use in commercial and private projects with minimal restrictions. Attribution is required but no copyleft obligations apply.

Quickstart

pip install backoff

import backoff

@backoff.on_exception(backoff.expo, Exception, max_tries=3)
def my_function():
    return requests.get(url)

Verify before relying

  • Whether the abandoned status and last commit in May 2024 pose a risk for your use case or Python version compatibility.
  • Whether asyncio decorator support is complete and tested for your async patterns.

Package facts

LicenseMIT permissive
Python supportSupports the current Python release >=3.7,<4.0
Install frictionLow. Pure-Python wheel
Runtime dependenciesNone
MaintenanceAbandoned 1,409 days since the last release
Last repo commit repository archived
First released
Downloads162,755,837 / month, #253 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
Development Status :: 5 - Production/StableIntended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseNatural Language :: EnglishOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9Topic :: Internet :: WWW/HTTPTopic :: Software Development :: Libraries :: Python ModulesTopic :: Utilities

Evidence: backoff-2.2.1-py3-none-any.whl

Tags

Capabilities
retry decoratorexponential backofffunction retry logicasync retry decoratornetwork request retrypolling with backoffexception retry handler
Topics
retry-logicasync-supportdecorator-pattern
PyPI keywords
retrybackoffdecorators

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “network request retry”

  • backoffProvides function decorators to automatically retry code on…
  • python-backoffProvides function decorators for retrying operations with…
  • pyramid-retrypyramid_retry wraps Pyramid requests with configurable retry logic,…

Give your agent the search over MCP, or paste the wish link into any chat.

More Python Modules packages

idna Worth it
PyPI · Python Modules · released Jun 2026

Converts domain names between Unicode and ASCII-compatible encoding (Punycode) according to IDNA 2008 and Unicode Technical Standard 46, with security validation and broader script coverage than the standard library.

Install it if you work with internationalized domain names, need to validate domains, or use HTTP clients that depend on it transitively.

BSD-3-Clausepure Python · 3.9+
1.8Bdownloads / mo
setuptools Worth it
PyPI · Python Modules · released Aug 2026

Setuptools is a Python build backend and package management tool that handles building, distributing, and installing Python packages, including support for C/C++ extension modules.

MITpure Python · 3.10+
1.6Bdownloads / mo
PyYAML Worth it
PyPI · Python Modules · released Sep 2025

PyYAML parses and emits YAML 1.1 data format, enabling serialization and deserialization of configuration files and Python objects to and from human-readable YAML text.

MITcompiled wheel · 3.8+
1.2Bdownloads / mo
pydantic Worth it
PyPI · Python Modules · released May 2026

Pydantic validates Python data structures against type hints, coercing and checking input at runtime to ensure it matches a declared schema.

MITpure Python · 3.9+
1.1Bdownloads / mo
annotated-types Worth it
PyPI · Python Modules · released Jul 2026

Provides reusable metadata objects for use with PEP-593 `typing.Annotated` to express common constraints like bounds, collection sizes, and predicates on types.

Install it if you use or build libraries that need to express type constraints in a standardized, inspectable way—or if you want to annotate your own types with…

MITpure Python · 3.10+
871.3Mdownloads / mo
typing-inspection Worth it
PyPI · Python Modules · released Aug 2026

Provides runtime tools to inspect and introspect Python type annotations, enabling programmatic examination of type hints at execution time.

MITpure Python · 3.10+
783.0Mdownloads / mo

See also backoff-utils · python-backoff · justbackoff · retry2 · reretry · waiter · python-retry · stamina · retry · botoinator