Problem with settings CORS policies on R2


Well, it turned out that my R2 access keys dad expired. Renewal of the keys solved my case.

I spent hours trying to figure out what’s going on with Cloudflare today. I just found out it was just a cache issue. After updating the CORS Policy, you must wait a few minutes to make requests to your files. If you made requests before updating your CORS policies, you will receive a CORS error until the cache is cleared.

1 Like

I am new to R2. I want to only allow origin. And then I set the Cors policy rule as follows:. but I can still access my file from anywhere. Please explain it to me. Thank you a lot.

    "AllowedOrigins": [
    "AllowedMethods": [