skillfed

b2sdk

Backblaze B2 SDK

b2sdk v2.12.0 536.0K downloads/30d#6,128 on PyPI211
Permissive license MIT Active released

What it is and what it does

B2SDK is a production-stable Python client for Backblaze B2 Cloud Storage. It wraps the B2 REST API to let you programmatically upload, download, list, and manage files and buckets from Python code. The library depends on requests for HTTP communication and includes utilities for logging and type annotations.

Typical use cases include building backup tools, storage backend drivers, FUSE filesystems, or any application that needs to interact with B2 Cloud Storage. The project is actively maintained, supports current Python versions (3.10 through 3.14), and follows semantic versioning so you can safely pin dependencies with version constraints like `b2sdk>=2,<3`.

Use it for:

  • Build a backup application that uploads files to B2 Cloud Storage programmatically.
  • Integrate B2 storage as a backend for a FUSE filesystem or virtual drive.
  • Automate file management tasks like batch uploads, deletions, or lifecycle policies.
  • Create a storage driver for backup software to use B2 as a destination.
  • Sync local directories to B2 buckets with custom logic and error handling.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

B2SDK is a Python client library for Backblaze B2 Cloud Storage that provides programmatic access to upload, download, list, and manage files and buckets in B2.

Yes. B2SDK is production-stable, actively maintained, has no known vulnerabilities, low install friction, and a permissive MIT license. Install it if you need to programmatically interact with Backblaze B2 Cloud Storage from Python. Pin to a major version (e.g., `b2sdk>=2,<3`) to avoid breaking changes.

Install

b2sdk on PyPI

pip

pip install b2sdk

uv

uv add b2sdk

poetry

poetry add b2sdk

Installing b2sdk

Before you install

Installation is straightforward with low friction—a single wheel distribution and four lightweight runtime dependencies (annotated-types, logfury, requests, typing-extensions). The project is actively maintained with recent commits and follows semantic versioning, making it safe to pin to a major version.

License in practice

Licensed under MIT (permissive), so you can use, modify, and distribute b2sdk freely in both open-source and commercial projects without restriction.

Quickstart

pip install b2sdk

from b2sdk.v2 import InMemoryAccountInfo, B2Api

info = InMemoryAccountInfo()
api = B2Api(info)
api.authorize_account('production', 'app_key_id', 'app_key')

Requires Python 3.10 or later; you must have valid Backblaze B2 credentials (app key ID and app key) to authorize.

Verify before relying

  • Whether the library supports async/await patterns or is synchronous-only.
  • Performance characteristics for large file uploads or bulk operations.
  • Whether retry logic and rate-limiting are built in or require manual handling.

Package facts

License MIT (permissive)
Python support supports the current Python release (>=3.10)
Install friction low — pure-Python wheel
Runtime dependencies 4 — annotated-types, logfury, requests, typing-extensions
Maintenance actively maintained — 101 days since the last release
Last repo commit
First released
Downloads 536,015/month — #6,128 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: b2sdk-2.12.0-py3-none-any.whl

Keywords: b2, backblaze, cloud, storage

Development Status :: 5 - Production/StableIntended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Topic :: Software Development :: Libraries

Tags

backblaze b2 cloud storage clientb2 sdk pythoncloud storage api wrapperb2 file upload downloadbackblaze cloud storage libraryobject storage python clientb2 bucket management
cloud-storagebackblazeapi-client

More Libraries packages