Skip to main content

Cloudflare R2 vs Backblaze B2: Zero-Egress Storage Battle

·APIScout Team
cloudflare r2backblaze b2object storagezero egresscomparison

TL;DR

Cloudflare R2 eliminates egress fees entirely at $0.015/GB storage. Backblaze B2 offers the cheapest raw storage at $0.006/GB with egress free up to 3x stored data. For web-facing workloads that serve files to end users frequently -- media delivery, CDN origins, public assets -- R2's zero-egress model delivers predictable costs regardless of traffic spikes. For storage-heavy workloads where data is written more than read -- backups, archives, media libraries, large datasets -- B2 saves 60% on storage costs. The power move in 2026 is pairing B2 with Cloudflare CDN via the Bandwidth Alliance: B2's rock-bottom storage pricing with unlimited free egress through Cloudflare's global network. Both platforms are S3-compatible, so switching requires changing an endpoint URL, not rewriting code.

Key Takeaways

  • B2 storage is 60% cheaper than R2. $0.006/GB vs $0.015/GB. For 10TB stored, B2 costs $60/month vs R2's $150/month -- a $1,080/year difference on storage alone.
  • R2 has unconditional zero egress. B2 has conditional free egress. R2 never charges for data transfer out, period. B2 offers 3x free egress (store 10TB, download up to 30TB free), with overages billed at $0.01/GB.
  • B2 + Cloudflare CDN eliminates the tradeoff. Through the Bandwidth Alliance, B2-to-Cloudflare transfers are free and unlimited. This combination delivers B2's $0.006/GB storage with zero egress via Cloudflare's 300+ global PoPs.
  • R2 has native edge computing. Cloudflare Workers bind directly to R2 buckets for serverless processing at the edge -- image transformation, access control, dynamic responses. B2 has no equivalent.
  • B2 has stronger compliance and backup features. Object Lock (WORM) for immutable storage, deep lifecycle rules, and native integrations with backup tools like Veeam, MSP360, Arq, and Synology.
  • Both are fully S3-compatible. Same API, same SDKs, same CLI tools. Migration between them is a configuration change.

Two Approaches to Cheap Storage

Cloudflare R2 and Backblaze B2 both exist because AWS S3 egress fees are too expensive. Both are S3-compatible. Both cost a fraction of what S3 charges. Both serve teams that decided paying $0.09/GB to download their own data is unacceptable.

They solve the problem from opposite directions.

Cloudflare R2 eliminates egress entirely. There is no charge to download data from R2 -- not through the S3 API, not through Workers, not through public URLs. Storage costs $0.015/GB/month, which is 35% cheaper than S3 Standard. R2 is embedded in Cloudflare's edge network, with native bindings to Workers, CDN, and DNS. The target workload is web-facing: serving images, videos, API responses, and static assets to end users at the edge with zero transfer cost.

Backblaze B2 makes storage itself as cheap as possible. At $0.006/GB/month -- roughly $6/TB -- B2 is the cheapest major object storage provider, beating R2 by 60% on raw storage cost. Egress is free up to 3x average monthly stored data. Beyond that threshold, overages are billed at $0.01/GB. Through the Bandwidth Alliance, egress to partner CDNs like Cloudflare, Fastly, and bunny.net is unlimited and free. B2 targets data-heavy workloads: backups, archives, media libraries, and large datasets where terabytes accumulate but retrieval is less frequent.

The decision comes down to workload shape. Storage-heavy? B2. Egress-heavy? R2. Both? The B2 + Cloudflare CDN combination.

Feature Comparison

FeatureCloudflare R2Backblaze B2
Storage cost/GB$0.015$0.006
Egress cost$0 (always)Free up to 3x storage; $0.01/GB after
Bandwidth Alliance egressNative (Cloudflare is the network)Free to Cloudflare, Fastly, bunny.net, Vultr
S3 API compatibleYesYes
Storage classes2 (Standard, Infrequent Access)1 (+ Overdrive tier)
Edge computingWorkers integrationNone
CDN integrationNative Cloudflare CDNVia Bandwidth Alliance partners
Object Lock (WORM)NoYes
Lifecycle rulesBasic (IA transition, expiration)Full (versioning, lifecycle, caps)
VersioningYesYes
Encryption at restYesYes
Multipart uploadYesYes
Max object size5TB100GB
Backup tool integrationsLimitedVeeam, MSP360, Arq, Synology, rclone
Jurisdictional restrictionsYes (EU, etc.)No
Storage regionsAutomatic (global)US West, US East, EU Central
Free tier10GB, 1M writes, 10M reads/month10GB, unlimited reads (within 3x)

R2 wins on egress certainty and edge computing. B2 wins on storage cost, compliance features, and backup ecosystem breadth.

Pricing at Scale

Cloudflare R2

ComponentCost
Storage (Standard)$0.015/GB/month
Storage (Infrequent Access)$0.01/GB/month
Class A operations (writes)$4.50/million
Class B operations (reads)$0.36/million
Egress$0

Backblaze B2

ComponentCost
Storage$0.006/GB/month
Class B transactions (downloads)$0.004/10K
Class C transactions (other reads)$0.004/10K
Egress (up to 3x stored data)$0
Egress (beyond 3x)$0.01/GB
Egress to Bandwidth Alliance partners$0 (unlimited)

Side-by-Side Cost Scenarios

ScenarioR2 CostB2 CostWinner
1TB stored, 500GB egress/month$15$6B2 (60% cheaper)
1TB stored, 5TB egress/month$15$26R2 (42% cheaper -- B2 exceeds 3x)
10TB stored, 10TB egress/month$150$60B2 (60% cheaper -- within 3x)
10TB stored, 50TB egress/month$150$260R2 (42% cheaper -- B2 overages stack up)
100TB stored, 50TB egress/month$1,500$600B2 (60% cheaper -- well within 3x)
100TB stored, 500TB egress/month$1,500$2,600R2 (42% cheaper -- massive B2 overages)

The crossover point is the 3x ratio. When monthly egress stays below 3x stored data, B2 is dramatically cheaper because storage is the only real cost. When egress exceeds 3x, B2's overage fees at $0.01/GB accumulate and R2's flat zero-egress model wins. For workloads near the boundary, the B2 + Cloudflare CDN combination eliminates the tradeoff entirely.

The B2 + Cloudflare CDN Combo

This is the most cost-efficient object storage architecture available in 2026. The Bandwidth Alliance between Backblaze and Cloudflare makes data transfer between the two platforms free and unlimited -- no caps, no thresholds, no fine print.

The setup:

  • Storage layer: Backblaze B2 at $0.006/GB (cheapest major provider)
  • CDN layer: Cloudflare (free plan or paid, both qualify for the Alliance)
  • Egress cost: $0 from B2 to Cloudflare (Bandwidth Alliance)
  • Delivery cost: $0 from Cloudflare to end users (Cloudflare never charges for bandwidth)

This combination delivers B2's storage pricing with effectively zero egress for any content served through Cloudflare's CDN. For a workload storing 100TB and serving 500TB/month:

  • R2 alone: $1,500/month
  • B2 alone: $2,600/month (overages beyond 3x)
  • B2 + Cloudflare CDN: $600/month (zero egress via Alliance)

The B2 + Cloudflare CDN stack costs 60% less than R2 for this scenario and 77% less than standalone B2 with direct egress.

The tradeoff is operational complexity. R2 is a single platform -- storage, CDN, edge compute, DNS all managed in one dashboard. The B2 + Cloudflare CDN approach requires configuring two separate services, managing cache invalidation, and handling origin pulls. For teams already on Cloudflare, the added complexity is minimal. For teams starting from scratch, R2's integrated experience may justify the higher storage cost.

Developer Experience

R2: Edge-Native Storage

R2's differentiator beyond pricing is Cloudflare Workers integration. R2 buckets bind directly to Workers running at Cloudflare's edge -- no network hop to an origin server, no egress fee, no added latency.

// Cloudflare Worker with R2 binding
export default {
  async fetch(request, env) {
    const url = new URL(request.url);
    const key = url.pathname.slice(1);

    if (request.method === 'PUT') {
      await env.BUCKET.put(key, request.body);
      return new Response('Uploaded', { status: 200 });
    }

    const object = await env.BUCKET.get(key);
    if (!object) return new Response('Not Found', { status: 404 });

    return new Response(object.body, {
      headers: {
        'Content-Type': object.httpMetadata?.contentType || 'application/octet-stream',
        'Cache-Control': 'public, max-age=86400',
      },
    });
  },
};

This pattern -- Workers as a programmable API layer in front of R2 -- enables image resizing, access control, PDF generation, A/B testing, and content transformation at the edge. No egress fees on any of it. For applications that need to process objects before serving them, R2 + Workers is a compelling combination that B2 cannot match.

B2: S3-Compatible with Backup Ecosystem

B2 supports the S3 API, so the same SDKs and tools that work with S3 and R2 work with B2. The endpoint changes; the code does not.

import { S3Client, PutObjectCommand, GetObjectCommand } from '@aws-sdk/client-s3';

const b2 = new S3Client({
  region: 'us-west-004',
  endpoint: 'https://s3.us-west-004.backblazeb2.com',
  credentials: {
    accessKeyId: process.env.B2_KEY_ID,
    secretAccessKey: process.env.B2_APP_KEY,
  },
});

// Upload a backup
await b2.send(new PutObjectCommand({
  Bucket: 'my-backups',
  Key: `backups/${Date.now()}.tar.gz`,
  Body: backupStream,
}));

// Retrieve when needed
const { Body } = await b2.send(new GetObjectCommand({
  Bucket: 'my-backups',
  Key: 'backups/1709856000000.tar.gz',
}));

Where B2 excels is the breadth of backup and infrastructure tools with native integrations. Veeam, MSP360, Arq, Synology, rclone, and dozens of other backup solutions support B2 as a storage target out of the box. For backup infrastructure where data is written on schedule and retrieved rarely, B2's ecosystem depth and low storage cost make it the natural default.

B2 also supports Object Lock (WORM -- Write Once Read Many), which R2 does not. This feature is required for regulatory compliance in industries that mandate immutable storage -- financial records, legal documents, healthcare archives. For any workload with immutability requirements, B2 is the only option between these two providers.

Use Cases

Best for Cloudflare R2

  • Media and asset delivery. Serving images, videos, fonts, and downloads to end users. Zero egress means a viral traffic spike costs nothing extra.
  • CDN origin storage. R2 as the origin behind Cloudflare's CDN. Objects are cached at 300+ edge locations and served without egress fees at origin or edge.
  • Edge-processed content. Workers reading from R2 to resize images, watermark files, generate thumbnails, or apply access control logic -- all at the edge, all without egress.
  • API response payloads. Storing and serving large JSON/binary payloads through API endpoints. Predictable cost regardless of API call volume.
  • Unpredictable egress workloads. Any application where download volume is hard to forecast. R2 eliminates the variable entirely.

Best for Backblaze B2

  • Backups and disaster recovery. Database dumps, server snapshots, application backups. Write frequently, read rarely. B2's $0.006/GB keeps archive costs minimal.
  • Cold and warm archives. Log archives, historical data, compliance records. Data that must be retained but is accessed infrequently.
  • Large media libraries. Petabyte-scale video, audio, or image archives where storage volume is the dominant cost. 60% savings over R2 at scale.
  • Immutable compliance storage. Object Lock (WORM) for financial, legal, or healthcare data that must be stored in a tamper-proof manner.
  • B2 + Cloudflare CDN serving. Store on B2, serve through Cloudflare. Best-of-both-worlds: cheapest storage, zero egress, global CDN delivery.

Recommendations

Choose R2 when the workload is egress-heavy or needs edge compute

R2 is the right default for applications that serve content to end users. Zero egress fees mean the cost model is simple: pay for storage and operations, nothing else. No tracking egress ratios, no monitoring 3x thresholds, no surprise bills after a traffic spike. The Workers integration adds a layer of capability that B2 cannot replicate -- serverless compute at the edge with direct bucket access.

Best fit: SaaS platforms serving user-uploaded files, media delivery pipelines, static site hosting, API backends with large response payloads.

Choose B2 when the workload is storage-heavy or needs compliance features

B2 is the right default for workloads where data accumulates faster than it is retrieved. The 60% storage cost advantage over R2 compounds at scale -- 100TB on B2 costs $600/month vs $1,500/month on R2, saving $10,800/year. Object Lock support makes B2 the only option for regulatory immutable storage between these two. The backup tool ecosystem (Veeam, MSP360, Arq, Synology) means operational infrastructure plugs in without custom development.

Best fit: backup infrastructure, disaster recovery, compliance archives, media asset management with infrequent access.

Use both: B2 for storage, Cloudflare CDN for delivery

The most cost-efficient pattern is hybrid. Store on B2 at $0.006/GB, serve through Cloudflare CDN with zero egress via the Bandwidth Alliance. This approach is increasingly common in 2026 for media-heavy applications, image hosting platforms, and any workload where both storage volume and egress volume are high.

Best fit: large-scale media platforms, image hosting services, content-heavy websites, any application currently paying significant S3 egress fees.

Methodology

  • Sources: Cloudflare R2 and Backblaze B2 official pricing pages, Cloudflare developer documentation, Backblaze documentation, Bandwidth Alliance partner list, and independent comparisons from ThemeDev, Onidel, and Taloflow
  • Pricing data: Official pricing pages as of March 2026
  • Feature data: Official documentation and changelogs from both platforms
  • Limitations: B2 Overdrive pricing and availability may vary. Bandwidth Alliance partner list and terms are subject to change. Volume discounts and enterprise agreements are not reflected. Operation costs (Class A/B/C) are excluded from scenario comparisons for clarity

Evaluating cloud storage for your stack? Compare Cloudflare R2, Backblaze B2, AWS S3, and more on APIScout -- pricing, features, and developer experience across every major storage API.

Comments