About 5 minutes
How to use Aktar with Cloudflare R2
Cloudflare R2 is a great match for Aktar: it has no egress fees, a free tier that covers most screenshot use, and custom domains served through Cloudflare's network. Aktar has a dedicated R2 preset, so you only need your Account ID, an API token and a bucket.
What you need
- A Cloudflare account with R2 enabled
- A domain on Cloudflare if you want links on your own domain (optional)
- Aktar installed on your Mac
Step by step
- 1
Create a bucket
In the Cloudflare dashboard, open R2 Object Storage and click Create bucket. Pick a short name such as
screenshotsand keep the automatic location. - 2
Give the bucket a public address
Open the bucket's Settings. Under Custom Domains, connect a domain or subdomain you manage on Cloudflare, for example
files.example.com. This is the best option for real use.For a quick test you can enable the Public Development URL (
pub-….r2.dev) instead. Cloudflare rate-limits that URL and doesn't recommend it for production. - 3
Create an API token
Back on the R2 overview page, open Manage API tokens and create a token with Object Read & Write permission, limited to your bucket. Copy the Access Key ID and Secret Access Key: the secret is only shown once.
Your Account ID is shown on the same page, and it's also the first part of the S3 endpoint
https://<ACCOUNT_ID>.r2.cloudflarestorage.com. - 4
Add the destination in Aktar
Open Aktar's Settings → Destinations → Add Destination, choose Cloudflare R2 and fill in the fields from the table below. Aktar derives the endpoint from your Account ID.
- 5
Test and save
Click Test Connection. Aktar uploads a tiny test file, checks that it's reachable through your public address and deletes it again. When everything is green, click Save and drop your first file on the menu bar icon.
Settings in Aktar
Enter these values in Settings → Destinations → Add Destination. Field names match the app.
| Field | Example value |
|---|---|
| Provider | Cloudflare R2 |
| Profile Name | PersonalAny name you like. |
| Account ID | 3f9a71c0e2b8…From the R2 overview page. |
| Region | autoKeep the default. |
| Access Key ID | a1b2c3d4…From the R2 API token. |
| Secret Access Key | ••••••••Stored in the macOS Keychain. |
| Bucket | screenshots |
| Public Base URL | files.example.comYour custom domain or the r2.dev URL. |
| Object Path | {year}/{month}/{uuid}.{ext}Optional, see file names and folders. |
Tips
- Limit the API token to the one bucket Aktar uses. If the token ever leaks, nothing else is exposed.
- A custom domain is cached by Cloudflare, so popular links load fast worldwide at no extra cost.
- Want tidy folders? Change the object path, for example to
shots/{date}/{filename}-{random}.{ext}. See file names and folders.
Troubleshooting
The link returns Access Denied or 403
Make sure the Public Base URL is your custom domain or r2.dev URL. The …r2.cloudflarestorage.com endpoint is only for the API and never serves public files. More in Access Denied errors.
Test Connection says the credentials are invalid
Use the Access Key ID and Secret Access Key from the R2 API token, not a regular Cloudflare API token or your Global API Key. Check that the Account ID has no extra spaces.
Uploads work but links are slow or rate-limited
You're probably using the r2.dev development URL. Connect a custom domain for production use.
Still stuck?Browse the FAQ or ask on GitHub.