DevOps & CloudDocumentedScanned

r2-storage

Cloudflare R2 Storage management — setup, upload, download, sync via rclone

Share:

Installation

npx clawhub@latest install r2-storage

View the full skill documentation and source below.

Documentation

r2 ☁️

Cloudflare R2 Storage management using rclone.

Install

curl -fsSL  | sudo bash

Credentials Required

Set R2_CONFIG in dashboard with this JSON format:

{
  "access_key_id": "YOUR_ACCESS_KEY_ID",
  "secret_access_key": "YOUR_SECRET_ACCESS_KEY",
  "endpoint": "",
  "bucket": "your-bucket-name"
}

Get credentials from Cloudflare:

  • Go to → R2

  • Create API token with Object Read/Write/List permissions

  • Copy Account ID (from R2 dashboard URL)

  • Endpoint format: ## Setup __CODE_BLOCK_2__ Or run interactively: __CODE_BLOCK_3__ ## Commands ### Upload __CODE_BLOCK_4__ ### Download __CODE_BLOCK_5__ ### List __CODE_BLOCK_6__ ### Sync (One-way) __CODE_BLOCK_7__ ### Delete __CODE_BLOCK_8__ ## Show Credentials __CODE_BLOCK_9__ ## Direct rclone Commands __CODE_BLOCK_10__ ## Config Location - **Env config**: ~/.config/r2/config.json (or dashboard R2_CONFIG) - **rclone config**: ~/.config/rclone/rclone.conf - **Named remote**: r2`
  • Troubleshooting

    403 Access Denied

    Token lacks permissions. Update API token in Cloudflare with:
    • Object Read ✅
    • Object Write ✅
    • Object List ✅

    Bucket Not Found

    Create the bucket first:
    rclone mkdir r2:bucket-name