Skip to main content

R2 Cloudflare community documentation

This documentation needs updating.

Could you please also add screenshots for each step.

Point 2: Generate API Key tokens Step 4, there is no R2 or R2 Storage, the only option you get is Workers R2 Storage.

Also, there is a confusion on how to obtain access key

  • Access Key: Paste the access key from your CloudFlare API token.

    If we use the global key I get following error:

    S3::getBucket(): [InvalidArgument] Credential access key has length 37, should be 32

https://github.com/WPManageNinja/fluent-community-docs/blob/master/configure-cloudflare-r2.md

Sella Yoffe

Agree. I'm also stuck with it.

Fernando Cardoso

Sella Yoffe, I resolved this using the Cloudflare documentation, steps 1 to 7. This method provides all the necessary data.

https://developers.cloudflare.com/r2/api/s3/tokens/

Manoj Sharma

Fernando Cardoso, how did you get the access key?

Fernando Cardoso

Manoj Sharma, When you complete the configuration, you will see all the data, access key, secret key.

Fernando Cardoso

Manoj Sharma, after finish setup, to get "Bucket Public URL", go to R2 Object Storage > Overview > select your Bucket > click "Settigns" > scroll to "R2.dev subdomain" copy the this URL, you must give access permission to that URL as well..

Manoj Sharma

Finally, it’s working, and the photos are successfully uploading to the storage! However, there seems to be an issue, as the photos are currently appearing as broken links. Shahjahan Jewel did you face a similar issue?

Manoj Sharma

Thanks, @Jewel, for updating the Cloudflare R2 Storage configuration document! I followed it, and it’s working fine now. πŸŽ‰

Here it is for everyone’s reference:
https://github.com/WPManageNinja/fluent-community-docs/blob/master/configure-cloudflare-r2.md