Skip to content

API

R2 provides three API surfaces for interacting with your data:

  • Workers API: An in-Worker API accessed by binding an R2 bucket to a Worker. Use the Workers API to read, write, and list objects from within a Worker.
  • S3-compatible API: An S3-compatible HTTP API available at https://<ACCOUNT_ID>.r2.cloudflarestorage.com. Use existing S3 SDKs and tools to interact with R2.
  • Cloudflare REST API: The api.cloudflare.com REST API used by the Cloudflare Dashboard and Wrangler CLI. Supports bucket management and object operations. Rate limits apply. Use the S3-compatible API or Workers API for high-throughput workloads.