Open In App

How to Install Drupal in Localhost with XAMPP on Windows?

Last Updated : 02 Jan, 2023
Improve
Improve
Like Article
Like
Save
Share
Report

Drupal can be understood as a content management framework that helps in building interactive web applications and websites. It is an open-source platform. The development credit for this platform goes to Dries Buytaert. It was initially launched in 2000. It was developed using the PHP programming language. It was built using a software architectural pattern. Installing Drupal to your computer or localhost is very simple and easy here in this article we are going to see how we can install Drupal. For installing Drupal to your local host first, you need some of the software which makes your computer the local server and runs Drupal smoothly. 

Software needs to Run Drupal

For running Drupal on your local host first you need to install the XAMPP server to your computer XAMPP makes your computer like the server. XAMPP is a cross-platform web server used to develop and test programs on a local server. It is developed and managed by Apache Friends and is open-source. It has an Apache HTTP Server, MariaDB, and an interpreter for 11 different programming languages like Perl and PHP. XAMPP Stands for cross-platform, Apache, MySQL, PHP, and Perl.

It makes turns the computer into a local host and you don’t need to do extra work for making the server. For installing the XAMPP to your local computer, check here. After the successful installation of the XAMPP server to your computer, now it’s time to install Drupal. 

Steps to Install and Setup Drupal 

Above we have seen how we can install the XAMPP server to our computer and be ready with all its setup. Now it’s time to see how we can install the Drupal CMS to our local host. For installing Drupal to your localhost follow these simple steps:

Step 1: Go to the Drupal official website and download its latest version from the website.

downloading-drupal

 

Drupal zip gets downloaded to your computer.

drupal-zip-downloaded

 

Step 2: Extract the zip file which you have downloaded. 

extracting-zip-file

 

Step 3: Now copy the extracted file of the Drupal zip file and paste it into the xampp > htdocs file. For convenience, we rename the extracted file as “drupal-gfg”.

pasting-file-into-xampp

 

Step 4: After pasting the Drupal project to the XAMPP in the htdocs folder, Now it’s time to open the XAMPP and start Apache and MySQL.

starting-apache-and-mysql

 

Step 5: Now open your favorite web browser, here we used the Chrome web browser and type the localhost. If the below UI opens in your browser then it means that XAMPP installation and everything is fine and now we can proceed with the further process.

localhost

 

Step 6: Create the database for the Drupal project in the phpMyAdmin, for creating the database now type the localhost/PHPMyAdmin in the browser and hit enter.

creating-database

 

phpMyAdmin dashboard will appear on your screen.

Step 7: Create the database in the phpMyAdmin, Click on the new link to create the new database for your Drupal project.

creating-new-database-for-drupal-project

 

Step 8: Type the database name, for the demo purpose here I type the “drupal-gfg” as the database name. Later in the installation of drupal, we used this name. And finally, click on the create button to create the database name.

creating-database-name

 

Step 9: After creating the database in the phpMyAdmin, now come to the browser and type the URL as the localhost and the folder name of the drupal project here in my case it is “drupal-gfg”.

http://localhost/drupal-gfg

choosing-language

 

After typing the http://localhost/drupal-gfg the drupal setup window will appear on your screen.

Step 10: Follow the instructions for the complete installation process of Drupal in your local host. Choose the language and then click on the “Save and continue” button.

clicking-save-and-continue-option

 

Step 11: In the next step, you have to select the installation profile, It’s recommended to choose the “Standard” profile for the installation process. After choosing the profile click on the “Save and continue” button for further process.

selecting-installation-profile

 

Step 12: Now you will see the following, PHP extensions and PHP OPCODE Caching error on your screen to resolve this error follow this simple step to solve it.

error-in-requirement

 

Step 13: Now open the XAMPP control panel and click on the “config” button under the Apache section. And then click on the PHP (php.ini).

clicking-php(php.ini)

 

Step 14: Add this code in php.ini to enable OP code caching.

[opcache]

zend_extension=php_opcache.dll

; Determines if Zend OPCache is enabled

opcache.enable=1

After adding this code in the php.ini file restart the apache server and refresh your page. you will find the OP code caching error gets solved.

op-code-caching-error

 

Step 15: Now its the time to solve the “PHP EXTENSIONS” error. here it is disabled to make it enable follow the below steps, Open the XAMPP control panel and click on the “config” button and open the PHP (php.ini).

opening-php(php.ini)

 

Step 16: After opening the file now find the “extension=gd” in the php.ini, for finding press “CTRL + F” and type extension=gd and you get the name. here you will find that it is commented by “;” remove this colon sign and save it.

extension=gd

typing-extension=gd

 

After uncommenting the “extension=gd” save the php.ini and then again restart the Apache server and refresh the page.

Step 17: If everything is ok then the next step will appear on your screen. the next step is for the database configuration.

Database-configuration

 

Step 18: Now, enter the database name which you have created above in the phpMyAdmin, for the localhost database username is “root” and the password is nothing leave the password blank.

entering-database-name

 

After entering the database details now click on the “Save and continue” button.

Step 19: After the database configuration Drupal starts to install on your localhost.

drupal-installing

 

Step 20: After the complete installation of Drupal, Configure site option will appear on your screen. Enter the details of the website such as the site name, site email address, site maintenance account, user name, password, and regional settings.

entering-details

 

Step 21: After filling in all their details click on the “Save and continue” button. Now your website will get successfully installed on your local host.

drupal-installed

 

This is how you can install the Drupal CMS on your localhost. Now you can start testing and learning everything about Drupal on your computer and you don’t need to purchase the web server.



Like Article
Suggest improvement
Share your thoughts in the comments

Similar Reads