This is a step by step guide shows how to install and setup Dropbox in Ubuntu 24.04 or Ubuntu 22.04 for both Desktop and Server in command line.
Dropbox is a popular file hosting service, that provides free account with 2 GB storage and paid plans for more features. It works on multiple platforms, including Android, iOS, Linux, macOS, Microsoft Windows, Windows Phone. With it, you can store files on cloud and access through different devices, or share files to your friends easily with a link.
Dropbox for Linux provides both graphical interface (indicator applet) and command line tool, meaning it can works on both Desktop and Server editions.
Install Dropbox in Ubuntu Desktop
For Ubuntu Desktop, the app is available to install through 3 different ways. They include:
- Deb package in system repository, works for Ubuntu with default GNOME (nautilus file manager), XUbuntu (XFCE Desktop with Thunar file manager), and Ubuntu MATE (MATE Desktop with Caja).
- Deb package from app website, works for all other desktop environments.
- Flatpak package, unofficial package runs in sandbox environment.
Option 1: Install Dropbox from system repository
For GNOME, MATE, and XFCE Desktops with default file manager, first launch “Software & Updates” tool, then make sure the multiverse repository is enabled under ‘Download from the internet’ section in first tab.
Then, press Ctrl+Alt+T
on keyboard to open up a terminal window, and run command to install dropbox:
sudo apt install nautilus-dropbox
In command, replace nautilus-dropbox
with thunar-dropbox-plugin
for XFCE, or caja-dropbox
for MATE. And, run sudo apt update
first to refresh system cache if the package not found.
Option 2: Install Dropbox using official Deb
For other Desktops, just download the official Deb package from its website via the link below:
Depends on your Ubuntu edition, choose download 64-bit (Intel/AMD) for 22.10 and later, or either 64-bit or 32-bit for 22.04 and earlier. Then, open terminal (Ctrl+Alt+T) and run command to install the downloaded .deb package:
sudo apt install ~/Downloads/dropbox*.deb
Option 3: Install Dropbox via Flatpak
For choice, Dropbox is available to install as Flatpak package runs in sandbox environment. It’s an unofficial package which hosts the source of the client at Github page.
The Flatpak package is NOT working properly (indicator menu refuses to open), but you can try it out by running the 2 commands one by one in terminal (Ctrl+Alt+T) window:
- First, run command to install the flatpak daemon:
sudo apt install flatpak
- Then, install Dropbox flatpak package:
flatpak install https://dl.flathub.org/repo/appstream/com.dropbox.Client.flatpakref
After installation, search for and launch dropbox from either start menu or Gnome overview screen depends on your desktop environment, though you may need a log out and back in to make app icon visible.
Login and use Dropbox
After installed the package, there should be a dialog pops-up and asks to restart Nautilus (or Caja/Thunar). Just click the Restart button, then click Next. In next dialog click “Start Dropbox”.
If you don’t see the dialog, or it’s closed mistakenly, then search and launch “dropbox” from start menu or Gnome overview instead.
Then, the ‘Dropbox Installation’ dialog will open and inform that it needs to download the proprietary daemon. Just, click “OK” then wait until the download & install process done.
When everything’s done successfully, an indicator applet should appear in system tray area. It automatically opens the authentication page in web browser asks you to login. While, the indicator menu as well provides an option for logging-in. If it does NOT work properly, try log out and back in or restart your computer.
NOTE: Dropbox free account so far only allows to link 3 machines. If you’ve reached that limit, then either upgrade your account, or login to dropbox website, go to ‘Manage Account -> Security’ and delete (un-link) unused machines.
After login, just go to the new created “Dropbox” folder in user home. Do any change in that folder will be auto-synced on all machines linked to the account. And, you can right-click on files in that folder for menu options including:
- Copy Dropbox link – so to access anywhere in web browser.
- Version History.
- View on dropbox.com
- View comments.
- Don’t sync to dropbox.com
And, the indicator menu provides option to access “Preferences“. Where you can set the auto-start, language, download/upload speed limit, proxy, and hidden folder, etc.
Install & setup Dropbox in Ubuntu Server
1. For Ubuntu Server without a desktop environment, just run command first to download the dropbox package, then extract it:
cd ~ && wget -O - "https://www.dropbox.com/download?plat=lnx.x86_64" | tar xzf -
If you’re running on old 32-bit machine (run uname -m
to tell), then replace x86_64
with x86
in command.
2. After command done, you got a .dropbox-dist
hidden folder includes all libraries for Dropbox.
By running the command below will start the daemon:
~/.dropbox-dist/dropboxd
It will output a URL link, ask you to visit it in any other machine with a web browser. Once logged in (using web browser), it will prompt that “This computer is now linked to Dropbox. Welcome xxx”.
3. After login your Dropbox account, press Ctrl+C
in Ubuntu server to quit the current command.
To verify if the daemon is running, use command:
ps ax |grep dropbox
In case it’s not running, run command to start it until you quit this session:
~/.dropbox-dist/dropboxd &
Finally, navigate to Dropbox folder.
cd ~/Dropbox
Make some changes in your Dropbox storage, then run ls
to verify if the changes got synced.
4. Dropbox provides a command line tool to manage the app. To get it, run command:
mkdir -p ~/.local/bin
wget https://www.dropbox.com/download?dl=packages/dropbox.py -O ~/.local/bin/dropbox
Then add executable permission:
chmod u+x ~/.local/bin/dropbox
After that, you may run dropbox --help
command to print how to use the command (may need a log out and back in first). To get a share link of a file, use command:
dropbox sharelink ~/Dropbox/filename
Some options including auto-start sadly do not work in my case.
5. To make dropbox auto-start, run command to create (edit) a schedule job:
crontab -e
Then hit Enter to use the default text editor. When it opens, add new line below in the bottom:
@reboot /home/ji/.dropbox-dist/dropboxd
Here do remember to replace ji to your username. Finally, press Ctrl+S to save, and Ctrl+X to exit.
Uninstall Dropbox
Depends on which package you installed, uninstall the Deb package by running command in terminal (Ctrl+Alt+T):
sudo apt remove --autoremove dropbox nautilus-dropbox caja-dropbox thunar-dropbox
To uninstall the Flatpak package, use command:
flatpak uninstall --delete-data com.dropbox.Client
For the Ubuntu Server, just delete the source folder as well as the command line tool.
rm -R ~/.dropbox-dist ~/.local/bin/dropbox
Also re-run crontab -e
and remove the line you added for auto-start at login.