How to Fix DigitalOcean Spaces Access Denied for New Files Uploaded

Digital Ocean’s (DO) Spaces is a Amazon S3 alike storage space that allows you to store and serve files. By default, permission of files uploaded to your Space buckets will be set as Private.

If you are trying to access these files (be it .txt, .jpg, .png, .pdf, etc) publically via browser, you will be redirected to an error page that looks something like the following:

xml access denied

We encounter the same problem while uploading files via Transmit to our Spaces bucket.

The good news is, it can be solved quite easily with adding the Amazon S3 Access Control List (ACL) request header, x-amz-acl. This header will mark every files uploaded to the bucket as publicly readable.

We can add this header to Transmit so it will send any files with the header. Once done, the files will appear with Permission: Public in the Digital Ocean dashboard.

Here’s how you can add the header:

  1. Launch Transmit, go to Preferences.
  2. step 01
  3. Click Cloud Tab.
  4. step 02
  5. Under the Extension column, select Default.
  6. step 03
  7. Click the + sign with dropdown, select x-amz-acl for Name, and public-read for Value.
  8. step 04
  9. Done!

If you’re currently connected to DO Space bucket via Transmit, you might need to disconnect and connect it again. From now on, files uploaded to your Spaces bucket via Transmit will by default be public and accessible via browser.

FacebookTwitterInstagramPinterestLinkedInGoogle+YoutubeRedditDribbbleBehanceGithubCodePenWhatsappEmail