R2 Local Uploads Now Available in Open Beta
Cloudflare has introduced Local Uploads for R2 object storage, a new feature designed to optimize upload performance for users with globally distributed traffic. The feature is now available in open beta.
How It Works
With Local Uploads enabled, object data is written to storage infrastructure geographically near the uploading client, then asynchronously replicated to your primary R2 bucket. This approach eliminates the performance penalty of uploading from distant regions while maintaining strong consistency throughout the process—objects are immediately accessible after the initial write.
Performance Gains
In Cloudflare's testing, Local Uploads delivered up to 75% reduction in Time to Last Byte (TTLB) for upload requests. The benchmark showed median latency dropping from approximately 2 seconds to 500ms, a significant improvement for applications where upload speed is critical.
Ideal Use Cases
Local Uploads is particularly valuable when:
- Your user base spans multiple geographic regions
- Upload performance and reliability are critical to your application
- You want to optimize write performance without relocating your bucket
Getting Started
Enabling Local Uploads is seamless with no downtime or traffic interruption. You can enable it through the Cloudflare Dashboard or via the Wrangler CLI:
npx wrangler r2 bucket local-uploads enable <BUCKET_NAME>
Pricing
There is no additional cost to enable Local Uploads. Upload requests incur standard Class A operation costs, the same as regular uploads. Existing uploads will continue to complete normally during the transition.