Fix a storage connection test error

Updated Oct 29, 2026 · 10 min read · All plans

This article explains each message the storage connection test can show, what it means in plain words, and how to fix it.

This is optional. PlayerMagick stores your videos for you, with nothing to set up. Connecting your own bucket is only for accounts where it is turned on: accounts that already used their own storage, and accounts where support turned it on at your request. See How PlayerMagick stores your videos.

How the test works

When you connect a bucket and click Test connection (or click Test now in Settings → Storage), PlayerMagick checks four things, in this order:

  1. "Wrote a test file": it saves a tiny text file in a folder called playermagick-check.
  2. "Read it back through the public URL": it loads that file from your Public URL for playback, the way a visitor's browser would.
  3. "Deleted it": it removes the test file.
  4. "Set up browser uploads (CORS) for you": it makes sure the player on your sales page is allowed to load your videos, and that you can upload from PlayerMagick straight into your bucket. It also checks that a CDN in front of your bucket (if you use one) passes this permission on to every visitor. For these checks it may save and remove one or two more tiny files in the same folder.

Each line is ticked as soon as its check is done. The whole test takes a few seconds and stops after about 45 seconds at most; a check that could not run in time is shown as skipped. If a check fails, the checks after it may be skipped. Fix the first failed check, then click Test again. It runs all four checks again from the start.

You can save a new connection only when all four checks pass. Save and continue stays greyed out until then.

A failed line shows a short explanation, the error code in small print, and a link to its section below. Support may ask you for the code. The messages in the app may be worded slightly differently from the headings below.

If you run many tests in a row (about 10 in a minute), PlayerMagick asks you to wait a minute before the next one.

The keys are not accepted

Error code: invalid_credentials

Your storage provider did not recognise the Access key ID or the Secret access key.

How to fix it:

  • Copy both keys again from your provider. Make sure nothing is missing at the start or end.
  • Check that you did not swap them: the access key ID is the shorter one.
  • If you deleted or rotated the key at your provider, create a new one.
  • Cloudflare R2: use the Access Key ID and Secret Access Key from the R2 token page, not the Token value. Check the Account ID too.
  • Backblaze B2: use the keyID and applicationKey of an application key, and check the region.

The bucket was not found

Error code: bucket_not_found

The keys work, but no bucket with that name exists where PlayerMagick looked.

How to fix it:

  • Check the spelling of Bucket name (lowercase, no spaces).
  • Check the region: a bucket created in eu-central-1 is not found in us-east-1.
  • Cloudflare R2: check that the Account ID is the one of the account that owns the bucket.

PlayerMagick never creates buckets for you. Create it at your provider first.

The key may not save files

Error code: access_denied_write

The keys are valid, but they are not allowed to save files in this bucket.

How to fix it: create a key with read and write access to this bucket (Cloudflare R2: Object Read & Write; Backblaze B2: Read and Write). If the key is limited to certain buckets, make sure this bucket is one of them.

The key may not delete files

Error code: access_denied_delete

PlayerMagick could save and read the test file but was not allowed to delete it. It needs to delete files to clean up old versions of your videos and unfinished uploads, otherwise your storage bill keeps growing.

How to fix it:

  1. Give the key permission to delete files, or create a new key with full read and write access to this bucket.
  2. Click Test again.
  3. The test file was left in the playermagick-check folder of your bucket. You can delete it at your provider; it is safe to remove.

The public URL can't be reached

Error code: public_url_unreachable

PlayerMagick saved the test file but could not load it through your Public URL for playback. Visitors would not be able to play your videos either.

How to fix it:

  • Check that the address is right and starts with https://. It should be only the address of the bucket or domain, without a file name at the end.
  • Check that public access is turned on at your provider:
    • Cloudflare R2: a custom domain showing Active, or the Public Development URL enabled.
    • Backblaze B2: Files in Bucket are set to Public.
    • Wasabi and Amazon S3: a bucket policy that allows public reads, or a CloudFront distribution that has finished deploying.
  • A new custom domain can take a few minutes to work. Wait and click Test again.

The public URL shows a different file

Error code: public_url_mismatch

Something answered at your Public URL for playback, but it was not the test file PlayerMagick had just saved. Usually the address points to a different bucket, a different folder, or a website (for example your homepage).

How to fix it: copy the public address again from your provider's bucket settings. If you use a CDN or a custom domain, check that it points to this bucket.

The player is not allowed to load your videos

Error code: cors_missing

The bucket has the CORS rules, but the permission does not reach visitors' browsers. This usually happens when a CDN or proxy sits in front of the bucket and removes the permission, or keeps serving an old copy.

How to fix it:

  • Amazon CloudFront: set the distribution's Origin request policy to CORS-S3Origin and wait until it has deployed.
  • Other CDNs: make sure the CDN passes the Origin request header to your storage, includes it in its cache key (so a copy saved for one visitor is not reused for another that needs the permission), and does not remove the Access-Control-Allow-Origin response header. Clear the CDN's cache.
  • Then click Test again.

PlayerMagick could not set up CORS

Error code: cors_not_permitted

CORS is the permission that lets the player on your sales page load videos from your bucket, and lets you upload from PlayerMagick straight into it. Your key is not allowed to change this setting, which is normal for keys limited to files (for example Cloudflare R2 Object Read & Write tokens).

How to fix it:

  1. Copy the rules PlayerMagick shows under the failed check, with the Copy button. They look like this:
[
  {
    "AllowedOrigins": ["*"],
    "AllowedMethods": ["GET", "HEAD"],
    "AllowedHeaders": ["Range"],
    "ExposeHeaders": ["Content-Length", "Content-Range", "ETag"],
    "MaxAgeSeconds": 86400
  },
  {
    "AllowedOrigins": ["https://app.playermagick.com"],
    "AllowedMethods": ["PUT"],
    "AllowedHeaders": ["*"],
    "ExposeHeaders": ["ETag"],
    "MaxAgeSeconds": 3600
  }
]
  1. Paste them in your bucket's CORS settings at your provider. Cloudflare R2: bucket → Settings → CORS Policy (see Connect Cloudflare R2 storage). If the bucket already has rules, keep them and add these two.
  2. Click Test again.

You cannot save the connection until this check passes, because your videos could not play on your pages without it.

The storage clocks do not match

Error code: clock_skew

Storage providers refuse requests whose time is too far from their own clock (usually more than 15 minutes), to stop old requests from being replayed.

How to fix it:

  • If you run your own storage server, set its clock to update automatically (NTP), then click Test again.
  • With Cloudflare, Backblaze, Wasabi or Amazon, the problem is on our side. Wait a few minutes and click Test again; if it still fails, contact support.

Your storage can't be reached

Error code: endpoint_unreachable

PlayerMagick could not connect to your storage provider at all.

How to fix it:

  • Check the region (and, for other providers, the Endpoint address and that it starts with https://).
  • Check your provider's status page for an outage.
  • If you run your own storage server, check that it is online, reachable from the internet, and has a valid security certificate. PlayerMagick does not connect to private network addresses or localhost.
  • Then click Test again.

Something unexpected went wrong

Error code: unknown_error

Your storage provider returned an error PlayerMagick does not recognise, often a short outage. Wait a few minutes and click Test again. If it keeps happening, contact support with the error code.

Reminders that do not stop you from saving

Sometimes all four checks pass but a line shows a reminder. You can save the connection; fix the reminder when you can. Saved reminders are also shown on the bucket's card in Settings → Storage.

"This address is for testing only"

Code: public_url_dev_only

Your Public URL for playback is a Cloudflare r2.dev address (it ends in .r2.dev). Cloudflare limits how many requests these addresses may serve and does not speed them up, so videos may load slowly or stop loading when many people watch.

How to fix it: connect your own domain to the bucket (see Connect Cloudflare R2 storage) and change the public URL to it. For a bucket you already connected, see Change the public URL for playback.

"Your CDN may block the player for some visitors"

Code: cdn_cache_ignores_origin

A CDN (or other cache) in front of your bucket keeps one copy of each file for everyone. When the first visitor's device asked without needing the permission (iPhones often do), the saved copy has no permission in it, and the next visitor on a computer may then get a video that does not load. This depends on who came first, so it can look random.

How to fix it: in your CDN, include the Origin request header in the cache key (it may be called "Vary on Origin", "cache by header" or a cache policy). Amazon CloudFront: keep the CORS-S3Origin origin request policy and use a cache policy that includes the Origin header in the cache key. Then clear the CDN's cache and click Test again.

"Cloudflare doesn’t keep copies of your videos yet"

Code: cdn_skips_video_files

Your videos play through your own domain on Cloudflare, but Cloudflare does not keep copies of the small files a streamed video is made of (it keeps only certain file types unless you tell it otherwise). Every viewer then loads them from your bucket, so videos start slower for viewers far from it, and Cloudflare counts more reads on your R2 bill.

How to fix it: add a Cache Rule for your video subdomain (see Connect Cloudflare R2 storage), wait a minute, then click Test now on the bucket's card in Settings → Storage.

Still stuck?

Contact support and include the provider, the region, the bucket name, the error code and a screenshot of the checklist. Never send your secret access key, to us or anyone else. Email support at support@playermagick.com.

Was this article helpful?