Flash Sale:75% Off Hosting + Free DomainEnds in13h47m14sView Plans
Hostvento logoHostvento

How to install Drush by hand

This guide shows you how to install Drush on your server step by step, without an automatic installer.

How-To Guides2 min read7 steps

What is Drush?

Drupal is a tool for building websites. Drush is a helper for Drupal. It lets you type short commands to do jobs like clearing the cache (saved copies of pages), updating modules, or running database updates. Drush is called a command-line tool, because you use it by typing, not clicking.

You need SSH access (a safe way to type commands on a server). You also need Composer, which is a tool that downloads PHP programs. If you are not sure your plan has SSH, ask Hostvento support.

Steps

  1. Connect to your hosting with SSH. Your details are in your welcome email.
  2. Check that PHP works:
php -v

This shows your PHP version.

  1. Check that Composer works:
composer --version

If it says "command not found", install Composer first by following its official instructions.

  1. Go to your Drupal project folder. This is the folder that holds the file composer.json:
cd ~/my-drupal-site

Change the folder name to match your own.

  1. Add Drush to the project:
composer require drush/drush

This downloads Drush into the vendor folder of your project.

  1. Run Drush to test it:
./vendor/bin/drush --version

You should see a version number.

  1. Run a real command from inside your site folder:
./vendor/bin/drush status

This shows your Drupal version, database state and paths.

Make typing easier

Typing the long path each time is tiring. Create a shortcut (an alias) for your session:

alias drush='./vendor/bin/drush'

To keep the shortcut, add that line to the end of the .bashrc file in your home folder.

Common problems

  • Not enough memory: Composer may stop. Try again with php -d memory_limit=-1 $(which composer) require drush/drush.
  • PHP version too old: new Drush needs a newer PHP. Pick a newer PHP version in your control panel, or ask support.
Tip: Take a backup of your site and database before you change anything with Composer.

Quick recap

  • Drush runs Drupal jobs from the command line.
  • You need SSH, PHP and Composer.
  • Run composer require drush/drush in the project folder.
  • Start it with ./vendor/bin/drush.
  • Back up before big changes.