Last updated June 10, 2016. Created on April 25, 2008.
Edited by rivena, HongPong, pranavbabbar, jmolivas. Log in to edit this page.

Drupal is available in two supported versions: the most recent and the previous. Currently that is Drupal 8 (released November 2015) and Drupal 7. The Recommended releases are the latest stable releases of either version. To learn more about versions, see the Drupal version information page.

To install a Drupal site in a language other than English, see http://localize.drupal.org/translate. You can also add additional languages after the installation.
Note: If you install Drupal 8, you can choose the installation language as the first option in the interface of the installation script itself.

You can download and extract Drupal in six different ways:

So, follow one of the methods below for downloading, and then...

Before continuing to the next page ...

The base URL for your Drupal installation is set in your web server's configuration file. You need to know this URL before proceeding to the next steps of the installation.
If you are installing Drupal on your local machine, the base URL may be http://localhost.
If you're installing Drupal to a web server, your base URL may be a specific domain name, such as http://example.com.

Drush

Drush is a command line tool to maintain and administer Drupal sites. It offers the most convenient way of downloading Drupal by using a single command: pm-download (or its alias dl):

drush dl drupal

This command will download the recommended version into the current folder. Check drush help dl to see additional options such as how to download a specific version.

Drupal Console

Drupal Console is the new command line interface (CLI) for Drupal. The Drupal Console is a tool to generate boilerplate code, interact and debug Drupal 8. It offers a convenient way of downloading Drupal by using a single command: site:new:

# specifying to download version 8.0.2 into folder "mydrupalsite"
drupal site:new mydrupalsite 8.0.2 

# select version from interactive mode
drupal site:new mydrupalsite 

This command will download the specified version into the current folder. Check drupal site:new --help or visit the documentation.

From the command line

Downloading

Log into your server on using ssh and navigate to the directory from which you will be serving your Drupal site.
On many *nix computers the path from the server's root will be /var/www/html, so cd /var/www/html. On a shared server, or a server that hosts multiple domains, the path will be different (try cd ~/www or cd ~/public_html). If you are unsure of the directory, ask your hosting provider for assistance.

Download Drupal from the command line, for example using wget or curl.
The commands are, respectively:

wget http://ftp.drupal.org/files/projects/drupal-x.x.tar.gz

or

curl -O http://ftp.drupal.org/files/projects/drupal-x.x.tar.gz

Note: The curl command option is the upper case letter "O" and not the numeral that stands for zero.

Replace http://ftp.drupal.org/files/projects/drupal-x.x.tar.gz with the link for the version you want to install.
The links to the recommended versions are available on Drupal Core project page, where you can copy them from the Download column.
All other versions are available on the Releases for Drupal core page.

Extracting files

Type the following command and replace "x.x" with your downloaded version's number:

tar -xvzf drupal-x.x.tar.gz

Then remove the compressed version of the file by using the following command:

rm drupal-x.x.tar.gz

Moving to its intended location

Now you need to move the contents of the drupal-x.x directory one level "up" into the web server's document root or your public HTML directory:

mv drupal-x.x/* drupal-x.x/.htaccess ./

For Drupal 7, also add:
mv drupal-x.x/.gitignore ./

Drupal 8 comes with several additional hidden files that all need to be moved as well.
Alternative, you can extract the the tar archive directly into the correct directory by typing:
tar --strip-components=1 -xvzf drupal-x.x.tar.gz

The files from the directory you downloaded and decompressed have now been moved up a level into your web directory, and you can delete the (now empty) drupal-x.x directory:

rmdir drupal-x.x

Using FTP

You can download Drupal using your favorite FTP-tool.

  1. Download a Drupal tar.gz or zip file to your local computer from https://www.drupal.org/project/drupal by clicking on the link for the version you want to install.
  2. When you download the file, your browser will ask you what to do with it. Choose "Extract" and extract it to your local computer. Or, save the file and extract it using your computer's software (7-zip for example) that deals with archive files. The exact steps to do this differ by software, but you should end up with a folder/directory called something like "drupal-7.32" on your local computer.
  3. Use FTP to transfer the entire contents of this folder, including hidden files like .htaccess, to your hosting account's HTML document root. Details of how to do this depend on your FTP software.

    Note: Drupal 8 includes about 10 times as many files as earlier versions (due to its new framework), that may take significantly longer to upload to a server by FTP than earlier versions. A faster way to upload Drupal 8 as a single ZIP files, suitable for some hosts is described here.

Using Git

The Drupal project page has great version control instructions, which starts with setting up repository for the first time by cloning Drupal.

When cloning Drupal 8.1.x or higher you will need to use composer to install the latest dependencies. From the root directory of the Drupal repository you cloned run composer install, this will download all the dependencies to the location expected by Drupal. See also this method for building sites with composer.

If you do not have composer installed follow their documentation.

Looking for support? Visit the Drupal.org forums, or join #drupal-support in IRC.

Comments

martinjbaker’s picture

Since
tar --strip-components=1 -xzvf drupal-x.x.tar.gz

eliminates the need to move files after extracting them, why not just give that code and then delete the entire "Moving to its intended location" section?

romdouze’s picture

Hi everyone,
Congratulations and thank you for this awesome work !

I followed this PHP recommended settings :

Setting: allow_url_fopen = off
Reason: This is a security issue: see here

but when i try to install Drupal console using

curl -LSs http://drupalconsole.com/installer | php

here is the result:

Drupal Console Installer

[-] Environment Check
 [*] You have a supported version of PHP (>= 5.4.10).
 [*] You have the "phar" extension installed.
 [*] You have a supported version of the "phar" extension.
 [*] You have the "openssl" extension installed.
 [ ] Notice: The "phar.readonly" setting needs to be off to create Phars.

 [*] The "detect_unicode" setting is off.
 [ ] The "allow_url_fopen" setting needs to be on.

SAme resulte when trying to install composer:

curl -sS https://getcomposer.org/installer | php
#!/usr/bin/env php
Some settings on your machine make Composer unable to work properly.
Make sure that you fix the issues listed below and run this script again:

The allow_url_fopen setting is incorrect.
Add the following to the end of your `php.ini`:
    allow_url_fopen = On

The php.ini used by your command-line PHP is: /etc/php.ini
If you can not modify the ini file, you can also run `php -d option=value` to modify ini values on the fly. You can use -d multiple times.

Did i miss something?

Thanks you again !
Romain

Kebz’s picture

I am getting errors left and right =\

I first extracted the file and then FTP into directory .... then I get these types of error message (one of many as an example)

Cannot mkdir: No such file or directory
drupal-8.0.1/vendor/fabpot/goutte/Goutte/

Then I decided to go SSH ... and same problem exists including this as an example

tar: drupal-8.0.1/LICENSE.txt: Cannot open: Disk quota exceeded
drupal-8.0.1/profiles/

Now what?? Please help!

~Kebz

Johan den Hollander’s picture

Did you extract the files there with the same server user as you are going to use to install Drupal?

If you downloaded the files there as root you will not be able to use them as a regular user since you also need write acces.

dnsahoo’s picture

Hi,

I am unable to install Drupal 8 on PHP 7 on Windows 10 and getting following error message

"Fatal error: Interface 'Drupal\Core\Entity\Schema\DynamicallyFieldableEntityStorageSchemaInterface' not found in S:\xampp\htdocs\drupal8\core\lib\Drupal\Core\Entity\Sql\SqlContentEntityStorage.php on line 44"

URL for this error is:

"http://localhost/drupal8/core/install.php?rewrite=ok&langcode=en&profile..."
Please suggest how to resolve this.

Thank You.

technologiclee’s picture

"Now you need to move the contents of the drupal-x.x directory one level "up" into the web server's document root or your public HTML directory:"

For Xubutnu 15.10 and Drupal 8.0.2 the correct directory was:
/var/www/html
The result looks like:
/var/www/html/drupal-8.0.2

I agree with @martinjbaker that it should just be saved and extracted here and there is no need to move it.

queenielow’s picture

Hi Everyone ,

This is not the 1st time installing drupal 8 but , it's my 1st time installing drupal 8.0.2.

I've got this error message "Fatal error: Cannot redeclare config_get_config_directory() (previously declared in /Library/Webserver/Documents/drupal8/core/includes/bootstrap.inc:143) in /Library/WebServer/Documents/drupal8/core/includes/bootstrap.inc on line 156" when I run http://mylocalsite.site/core/install.php ( which suppose to be the UI on installation steps)

I've tried to search around google and also in Drupal.org and I have no clue.. I thought there was really redeclare fucntion but i have search all over and there's only 1 function config_get_config_directory().

Any idea where I would have miss?

Thanks,
Qe

mglaman’s picture

This was a bug on case insensitive issues and has been fixed, https://www.drupal.org/node/2464055.

queenielow’s picture

Thanks for the link.. it does work for me..

Cheers,
Queenie

devjadhao’s picture

During drupal installation I am getting this error ,can any one see the issue??

Error
The website encountered an unexpected error. Please try again later.
Drupal\Core\Config\UnmetDependenciesException: Configuration objects (block.block.bartik_help, block.block.bartik_search, block.block.seven_help, core.entity_form_display.node.article.default, core.entity_form_display.node.page.default, core.entity_form_display.user.user.default, core.entity_view_display.node.article.default, core.entity_view_display.node.article.teaser, core.entity_view_display.user.user.compact, core.entity_view_display.user.user.default, field.field.node.article.field_image, field.field.user.user.user_picture, field.storage.node.field_image, field.storage.user.user_picture, rdf.mapping.comment.comment, rdf.mapping.node.article, rdf.mapping.node.page, rdf.mapping.taxonomy_term.tags) provided by standard have unmet dependencies in Drupal\Core\Config\UnmetDependenciesException::create() (line 89 of core\lib\Drupal\Core\Config\UnmetDependenciesException.php).
Drupal\Core\Config\UnmetDependenciesException::create('standard', Array)
Drupal\Core\Config\ConfigInstaller->checkConfigurationToInstall('module', 'standard')
Drupal\Core\ProxyClass\Config\ConfigInstaller->checkConfigurationToInstall('module', 'standard')
Drupal\Core\Extension\ModuleInstaller->install(Array, )
Drupal\Core\ProxyClass\Extension\ModuleInstaller->install(Array, )
install_install_profile(Array)
install_run_task(Array, Array)
install_run_tasks(Array)
install_drupal(Object)

queenielow’s picture

Hi devjadhao,

Which drupal 8 version are you installing? and on which platform?

Or you can try previous drupal8 version to see if you are getting the same error.
https://www.drupal.org/node/3060/release?api_version[]=7234

Cheers

devjadhao’s picture

hi queenielow,
Many Thanks for your reply..
I was installing Drupal 8.0.3 on windows 7 and It got resolved by reinstalling both xampp & drupal.

queenielow’s picture

Awesome! :)

DocDJ-forum’s picture

download button downloads only a bug-fix release, not a CLEAN FRESH INSTALL. There is no install.php file. It is labeled as 8.0.5. The instructions in this discussion say to use the install.php file, but it is absent in the download. I want to upgrade my D7 site to D8 EVENTUALLY, but for now I just want to build a D8 site. I have not been able to find a true basic install of D8.

For an upgrade, can I just copy the downloaded files on top of my existing files (and fix settings.php by hand)? I am hosting Drupal on my own PC, so I have full access to everything, or copy them, then re-run my OLD install.php. the instructions here are not clear on that.

regards,
DJ

mk1129’s picture

Use FTP to transfer the entire contents of this folder, including hidden files like .htaccess, to your hosting account's HTML document root.
Which folder is the root?
For example, I have installed C:\xampp and enabled Apache, MySQL and FileZilla.

Many thanks!

DocDJ-forum’s picture

Thanks, but I understand how to install a fresh copy via FTP. My problem is that the LINKS for Drupal 8 do NOT point to a FULL distribution. They only point to a BUG-FIX release. I want to find D8.0.0 so I can download the WHOLE release, then update it as needed.

regards,
DJ

gapple’s picture

In Drupal 8, the install.php file is located within the /core/ folder, instead of at the root level as in Drupal 7.
If you try to visit /install.php on your site, you will be redirected to /core/install.php

waterlovinguy’s picture

As per the git section, "composer install" did not work for me after installing composer, but "php composer.phar install" did.

Maybe that's obvious to some, but hopefully this helps someone else.

pvasili’s picture

I try wget http://ftp.drupal.org/files/projects/drupal-7.44.tar.gz and see:

Connecting to ftp.drupal.org|185.31.17.68|:443... connected.
ERROR: Certificate verification error for ftp.drupal.org: unable to get local issuer certificate
ERROR: certificate common name `j.ssl.fastly.net' doesn't match requested host name `ftp.drupal.org'.
To connect to ftp.drupal.org insecurely, use `--no-check-certificate'.
Unable to establish SSL connection.

:(