How to backup your files to Dropbox using bash

Download the dropbox-uploader script by Andrea Fabrizi from github as root

wget --no-check-certificate

make it executable and run it

chmod +x

when executed for the first time you will be prompted with some some instructions to be able to upload/download to your dropbox account.
In short, you need to create a developer account and create an app that this little script will talk to.
So, head over to :

and click on “Create an App”, fill in the form with the following data:

App name: MyUploader<number>
Description: What do you want…
Access level: App folder or Full Dropbox

Now, click on the “Create” button.

When your new App is successfully created, please enter the App Key, App Secret and the Access level into the script:

# App key: <key>
# App secret: <secret>
# Access level you have chosen, App folder or Full Dropbox [a/f]: 

The script will then show a confirmation question, if all information is correct, enter “y”
The script will now display:

Token request... 

while requesting access and if all is well it will turn into:

Token request... OK

A URL is now displayed that you need to visit to confirm access for the Dropbox Uploader to your dropbox account.
it will look something like this:<token>

Press enter when done…
If you take to long time to visit the URL, you will need to CTRL+C and start over again. If everything went ok, you will see this:

Access Token request... OK

Setup completed!

You can now upload/download files to your dropbox account with cli.


         upload   [LOCAL_FILE]  
         download [REMOTE_FILE] 
         delete   [REMOTE_FILE/REMOTE_DIR]
         mkdir    [REMOTE_DIR]
         share    [REMOTE_FILE]