Self hosting your cloud


Today, large technology companies such as Apple and Microsoft have a monopoly on your data, from storing your photos in iCloud Photos to storing your documents conveniently in OneDrive. But what if you’re not comfortable allowing other companies full control over your files, or (like me) you’re dirt poor and need a cheaper alternative to the increasing prices of cloud storage? Let’s take back control of our files!

A simple file server can be built using a Raspberry Pi or an old computer you don’t need. If you don’t have any of these lying around, you could use a VPS (Virtual Private Server) and have your files in the cloud for free, with a self-managed encryption key if needed. I use a Raspberry Pi 4 4GB for my home lab.

My untidy Pi setup, hidden under the stairs

Over the last year, I have tried different software for file storage and sharing. Each method has it’s own advantages and disadvantages, depending on your needs. For me, I needed:

  • Simple file storage on an external HDD
  • Access to files from anywhere globally
  • Fast read and write on local network
  • Offsite backup solution
  • Easily share files with friends and family

The solutions I will discuss will have features that I did not personally use but could still be useful for you, such as local file encryption. Let’s get started.

Nextcloud


Nextcloud (formally known as Owncloud) is a full self-hosted platform which not only offers file storage, but also offers features such as self-hosted chat and video calls, browser office integration and a calendar, to name a few. I will be mainly discussing the file hosting and sharing features however, as I had no practical use for anything else on the platform.

Nextcloud Hub II is the world’s most deployed collaboration platform, used by tens of millions of private users, governments, and fortune 500 companies alike to regain data sovereignty and privacy. With Nextcloud, users can share, discuss, and collaborate on documents, track and coordinate work, or organize video calls.

Nextcloud.com

Nextcloud is available to install easily on Raspberry Pis as an image, but is also available to install as a snap package and docker container. I initially installed Nextcloud using the snap package, but found that afterwards my installation was plagued with issues, so I opted for a manual install. The manual install comes with some assembly required, and you will need to be prepared to be Googling for errors for hours on end on your first installs.

As Nextcloud is mainly a web platform, it is essentially required to have your own domain name. You can purchase one for around £6 a year.

After a successful install, you can log in using your credentials. The website GUI is both aesthetically pleasing and easy to use and navigate. It is trivially easy to tweak settings and share uploaded files.

The Nextcloud dashboard | Nextcloud.com

Files can be easily accessed from any device using either the web dashboard or the provided Desktop and Mobile apps. The Windows desktop version also allows for virtual files, allowing you to access your Nextcloud data as if it were a folder on your computer, without taking extra space.

Backups are also simple to do, since the files are stored as original in the user data directory. Backing the files up is as simple as copying that data directory elsewhere, or in my case, using rclone to upload the files to Backblaze B2.

The Nextcloud community is also very active, with users in forums available to answer your questions and up to date documentation for you to read. The platform is constantly receiving new updates and improvements, making it a great solution for long term projects.

However, you may find that Nextcloud is too much for your needs. If all you need is simple file storage and sharing, you will find many of the features offered by Nextcloud redundant and difficult to maintain. I found that Nextcloud’s web GUI can occasionally be buggy and viewing files from the web GUI can also feel unresponsive. I ended up re-installing Nextcloud multiple times to fix issues, an endeavour which always took away my evenings.

Pros

  • Easy to use web GUI
  • Many features available (e.g. texts and calendar)
  • File sharing is easy and quick
  • Access files from anywhere
  • Desktop and mobile apps available
  • Active development and community
  • Accessible user data directory for backups
You can try the Nextcloud demo here.

Cons

  • Can be challenging to install
  • Web GUI for files can feel unresponsive
  • Requires a domain name
  • Occasional UI glitches

Seafile


Seafile is a solution designed for file sync and sharing. It is certainly not as popular as Nextcloud, but it’s performance and reliability puts it as a strong option for your self hosted file server needs.

Seafile is an open source file sync&share solution designed for high reliability, performance and productivity. Sync, share and collaborate across devices and teams. Build your team’s knowledge base with Seafile’s built-in Wiki feature.

Seafile.com

Seafile is available to install using a community install script. However, this script does not support the Raspberry Pi, so Pi users will have to follow the manual installation method from the Wiki. The Seafile server also has a “Pro edition”, which is free for up to 3 users and provides many features not available otherwise in the community edition. It should be noted that Seafile Pro is not available for the Raspberry Pi easily. Once again, some assembly is required when installing Seafile, especially on Raspberry Pi. However, the Seafile community is very active and many users will be available to assist you with any issues.

Like Nextcloud, Seafile is a web solution and essentially requires a domain name.

The Seafile demo dashboard

Seafile’s web GUI is incredibly simple and easy to use. The design is simple, and menus and settings are easy to reach. It is once again extremely easy to upload, download and share files from the web dashboard, and a desktop and mobile app is also available. The Windows client also has access to Virtual Files as mentioned earlier, allowing you to read and write to your drive as if it were a real folder on your local machine.

However, Seafile does not offer any other services and features other than file sync and sharing, unlike Nextcloud, which allows you to a whole suite of tools for your personal cloud. This does come with it’s advantages, though – Seafile is considerably faster than Nextcloud, and is incredibly responsive.

Seafile also features a GitHub-like commit system, where changes to files and logged and can be restored easily. This is achieved by storing files as chunks instead of as themselves. Smaller chunk sizes save more space, but can increase the amount of files on your local server dramatically.

Because Seafile stores your files as chunks instead of files, backing said files up can be incredibly difficult. Seafile has a tool called seaf-fuse, which allows you to access the chunks like a full file-system. However, this process can be slower and I experienced issues with rclone. While it is possible to backup the chunks individually, the large number of files and the difficulty of restoring chunks to original files makes this an almost impossible task. It is for this reason that I stopped using Seafile after a few months, despite the speed and ease of use.

Pros

  • Intuitive and simple web GUI
  • Incredibly fast UI and file transfer
  • Easy file sharing
  • Reliable
  • Commit/undo system
  • Access files from anywhere
  • Desktop and mobile apps
  • Active community and development
You can try the seafile demo here.

Cons

  • Can be challenging to install
  • Requires a domain name
  • Backups are very difficult
  • Not very customisable

Samba


Samba is a piece of server software that allows you to access a folder as a network share.

Samba is the standard Windows interoperability suite of programs for Linux and Unix.  Since 1992, Samba has provided secure, stable and fast file and print services for all clients using the SMB/CIFS protocol, such as all versions of DOS and Windows, OS/2, Linux and many others.

Samba.org

Unlike other solutions mentioned above, Samba is not web-based. It runs on your local network, allowing you to read and write directly to a network directory. The files are stored on a local folder in your Samba server.

Samba shares are mounted as network locations in Windows

Samba is very easy and simple to install. SMB shares can be accessed directly from your OS’s file explorers and performance is quick. However, you will not be able to access your Samba shares from outside your local network without a VPN. I use Tailscale which allows for easy access to my internal servers without port forwarding.

Pros

  • Easy to install
  • Incredibly fast
  • Simple to use
  • Easy to backup

Cons

  • No web dashboard
  • External access requires VPN

Conclusion


I hope that this article has been useful for deciding which solution you want to use for your own personal self-hosted cloud. I ended up using Samba with Tailscale as this solution was incredibly simple and easy to maintain – however, I can recommend every solution here. Which solution you decide to use will be up to your own requirements.