How to add Storj to Nextcloud "as external storages"?

Ah it looks like I got it working. Here are steps I did:

1 - Downloading files (uplink and gateway):

  1. curl -L -o && unzip
  2. curl -L -o && unzip
  3. chmod 755 gateway
  4. chmod 755 uplink

2 - Setting up (uplink):

  1. ./uplink setup
  2. Create a bucket by running ./uplink mb sj://example (See /dcs/api-reference/uplink-cli/ for other commands like deleting/removing a bucket, listing files inside a bucket, etc.)

3 - Setting up (gateway):

  1. screen (to let gateway run on another screen)
  2. ./gateway setup (See /dcs/api-reference/s3-gateway/ for more detail)
  3. ./gateway run
  4. Make sure to copy Endpoint, Access key, and Secret key to somewhere safe (like a password manager)

4 - Setting up (Nextcloud):

  1. Open External storages setting page
  2. Input a folder name
  3. Select Amazon S3 for External storage
  4. Select Access key for Authentication type
  5. Input example for Bucket (See above: 2.2)
  6. Input for Hostname (See above: 3.4)
  7. Input 7777 for Port (See above: 3.4)
  8. Leave Region blank
  9. Check Enable Path Style
  10. Paste your Access key (See above: 3.4)
  11. Paste your Secret key (See above: 3.4)
  12. Click three-dot-icon for advanced settings
  13. Click check mark to complete the configuration

And the external folder should be available!

If you want to sync the folder to your local machine, open the Nextcloud client and follow the instruction displayed there.

Please make sure that syncing the external storage with other machines multiplies the bandwidth. Also storing a bunch of tiny files can be costly (See: Nextcloud on Storj? - #17 by kevink).

On Tardigrade there are three ways of calculating fees (Object Storage fee, Per Object Fee, Bandwidth Fee). I would recommend you to read carefurelly before you move your files to the external folder on your Nextcloud instance.

While Storj have arrived at 1.0 the procedures written above are subject to change after future release. Please follow periodically for available changes.

Also according to @kevink:

1 Like

I’m looking into linking my nextcloud server with storj dcs. Are the above steps still valid and/or is there an up-to-date howto to do so?
Thanks in advance!

Hi @silaxe nobody has told me anythin about an update to those instructions. Therefore, I think they should still work. What happens when you step through it? thanks!

1 Like

Thanks Jocelyn! I will do this in the next days and will get back to you with my feedback.


Hi all,
I have managed to set up storj as external storage for nextcloud thanks, among others, to Andisers’ explanations. I am using it for backup purposes.
Is anyone using storj for nextcloud as primary storage? I’d be interested to do this in the long run but would like to know first how fast and reliable this option is.

I’ve worked on an app for Nextcloud so that you don’t need the S3 gateway. You can install it through the app store Storj - Apps - App Store - Nextcloud

Perhaps you can give it a try and see if you like it.

Is anyone using storj for nextcloud as primary storage? I’d be interested to do this in the long run but would like to know first how fast and reliable this option is.

I have not done a thorough comparison but I have some decent guesses

  • You’ll use more Storj bandwidth from things like tumbnails and generated assets and whatever apps decide to put there.
  • File browser will be faster because all the metadata is in the local SQL database
  • Other parts of Nextcloud may be slower.
  • Less chance of bugs because Nextcloud is treating Storj as a simple key-value store rather than as a file system.

It doesn’t sound like the best fit for Storj but should work fine.