This website uses cookies

Our website, platform and/or any sub domains use cookies to understand how you use our services, and to improve both your experience and our marketing relevance.

📣 Try the fastest hosting platform with pay-as-you-go pricing & 24/7 expert support! MIGRATE NOW →

A Guide for Upgrading a Drupal 7 Website to Drupal 8

Updated on July 13, 2023

7 Min Read
drupal-7-to-drupal-8

Kudos to you if you’ve already ventured into the awesome realms of Drupal 8. Now, as far as being on the cutting-edge goes, the next thing you will need on this adventure is to know how to update Drupal to the latest version.

In this tutorial, I am going to take you through the process of upgrading your website to Drupal 8.

Note: The alternate upgrade method uses Drush. I will cover this process in a later tutorial.

Optimize Drupal with Managed Hosting for Unbeatable Performance

Unleash Drupal brilliance effortlessly with our optimized hosting, ensuring seamless performance and expert management.

Pre-Upgrade Checklist

Before you start with the migration, it is a good idea to go through the following checklist and ensure you check off all the items:

Overview of the Required Migration Modules

Drupal 8 core comes bundled with the following migration modules:

  • Migrate: This is the core upgrade API module.
  • Migrate Drupal: This module consists of all the classes that are required for migration/upgrade from Drupal 7 to Drupal 8.
  • Migrate Upgrade: This is the module that provides the user with a simple and easy to use UI for performing the migration from Drupal 7 to Drupal 8.

Note: Earlier, there used to be a migrate_plus module in Drupal 8 core which contained all the pieces of migrate functionality that wasn’t able to make it in the Drupal 7 core. It contained all the plugins for the support of XML, CSV and JSON data sources along with the support for databases like MS SQL or Oracle. This module has now been split into different modules, namely migrate_plus , migrate_tools and migrate_source_csv .

Potential Problems

You might face two problems during the migration/upgrade process:

  • Missing migration paths
  • Contributed modules might not migrate properly to Drupal 8

Identify Contributed Modules

First of all, make a list of all the contributed modules on your current website. Next, check whether these modules have a Drupal 8 compatible version. In case of unavailability of the Drupal 8 version, the migration process will suffer. Fortunately, Drupal 8 has come a long way, and many major modules now support Drupal 8. You can check all the available update paths through the Migrate UI modules.

available upgrade paths

Upgrade Drupal

Make sure that you have checked off all the items on the pre-upgrade checklist. It is time to start the actual migration process. The following steps make up the upgrade process.

Make a Local Copy of the Website

The very first thing you should do is to make a local version of the website. This is an essential step because making changes to a live website is very risky and is never a recommended practice. This way, if anything does go awry, your actual website will remain safe and functional. This precaution ensures that in case of any unforeseen issues, your actual website, fortified by reliable Drupal hosting, will remain secure and fully functional.

Get the Latest Drupal 8 Version

Next, go to the official Drupal site and download the compatible version of Drupal 8.

drupal 8 download

Make a Local Drupal 8 website

Once the download finishes, setup a local Drupal 8 website on your machine. This website will be used as the destination website for the migration. Again, this website should be built in the local environment to avoid any harm in case of a disaster!

Verify Migrate Upgrade Modules

When you are done with setting up a local Drupal 8 website, navigate to the Extend tab of the new website and verify that the three main migrate modules (Migrate, Migrate Drupal and Migrate Upgrade) are present in the Core (experimental) section.

Enable the Modules

After verification, enable the module and click the Install button located at the bottom of the page.

main migrate modules

Navigate to the upgrade path

When done with the installation of the modules, you will have to navigate to the upgrade path. For this, go to www.yoursite.com/upgrade (remember to replace your site with the name of your Drupal 8 website). You will be brought to the following screen. Please make sure you follow the directions on the screen before proceeding.

upgrade paths

Enter the Details

After clicking Continue, you will be brought to the screen in the following screenshot. Enter all the required details such as your existing website’s credentials, the database location and the location of your website files.

site upgrade details

Make sure you enter the correct details and double check before proceeding.

Start the Migration

After proceeding, you will be brought to the Migrate UI where you can check all the potential issues and errors that you might encounter as well as all the available and the missing paths. Go through this screen and when satisfied, start the migration.

Note: The upgrade will take some time, depending on the size of your website. In case of errors, just reload the web page.

Drupal 8 comes to its end of life on November 2, 2021. Still, Drupal 8 has something for everybody who underpins your organization’s online content and digital experience: trade choice makers, site administrators, digital marketers, content managers, web engineers, technical designers, and IT pros. Drupal 8’s core platform has more than 200 modern built-in features.

Drupal is generally better-protected, but WordPress can hold its claim with the right steps: Drupal can handle PCI compliance prerequisites such as database encryption or other complex security circumstances.

Please note that in the world of Drupal, “Upgrade” means changing to a major version such as from Drupal 7 to Drupal 8. On the other hand, to Update Drupal core means updating to a minor version such as from Drupal 8.2.5 to Drupal 8.2.6.

In this tutorial I am going show you the steps needed to upgrade your Drupal 8 version to its latest releases.There are three main ways to update Drupal 8 Core, which are:

  • Via Composer
  • Via Drush
  • Manually

Since the composer and Drush methods are the easiest ones, I’ll show you how to update using these first. If in case, you aren’t able to update using these methods, you can go with the manual method which is a bit more complex but more thorough. It is a good practice to activate maintenance mode from your Drupal admin area before making any changes to your site.

Note: Make sure to always backup your site before attempting to update to avoid any loss of data in case of any mishap.

Improve Your Drupal App Speed by 300%

Cloudways offers you dedicated servers with SSD storage, custom performance, an optimized stack, and more for 300% faster load times.

Update Drupal via Composer

Composer is a very powerful dependencies management tool for PHP based applications. To read more about Composer, you can head over to its official page for Drupal.

To update via composer simply run the “composer update” command in your site’s CLI (Command Line Interface).

command-line-interface

Note: Composer is pre-installed on Cloudways servers.

Update Drupal via Drush

Drush is a shell interface for Drupal that allows you to perform administrative tasks from your cloud server command line itself. If you prefer using Drush over composer to update your Drupal core, you can follow the step given below to achieve that.

  1. Install Drush: To learn how to install Drush you can head over here .
  2. Backup: Always backup your site before making any core changes. You can make a backup of your site via drush through this command: drush archive-dump
  3. Put site in maintenance mode: As i mentioned before, it is always recommended to put your site in maintenance mode prior to making changes in your site. You can do this through Drush through the following command: drush sset system.maintenance_mode 1
  4. Run Update command in Drush: Now you need to run the following command to perform the update: drush pm-update
  5. Put site online: After update is performed, enter the following command to put your site back online: drush sset system.maintenance_mode 0

That’s it. It’s as simple as entering 3 commands to update your Drupal 8 core to drush.

Manually Updating Drupal 8 Core

This is the most tedious method but also the one which is most thorough. The steps involved in this method are as follows:

  1. Download and extract the latest version of Drupal from here .
  2. Login to your site’s admin panel using your admin credentials.
  3. Backup your database (ex: through PHPMyAdmin) and website before proceeding.
  4. Put your site in maintenance mode by navigation to configuration -> maintenance mode
  5. Remove ‘core’ and ‘vendor’ directory from your project. Also remove all the files from your project’s top-level directory, leaving out any files that you made changes to.
  6. Upload the core directory from the Drupal version you downloaded in step 1 to your project.
  7. Upload .htaccess, composer.lock and composer.json files from the downloaded Drupal version to your project.
  8. Upload vendor directory from the download Drupal version to your project.
  9. Go to yoursite.com/update where “ yoursite ” is your website’s domain name.
  10. Follow the onscreen instructions.

Seamless Drupal Hosting: Unleash the Potential with Cloudways!

Optimize your Drupal site’s potential with our managed hosting – discover elevated performance and peace of mind.

Conclusion

Updating your Drupal 8 core is a pretty straightforward and easy task once you grasp the basics of it. It is very important to update Drupal core for a variety of reasons which I will cover in a future article, so be sure to stay tuned for that.

We also saw in this article how tools like Composer and Drush make it incredibly easy to update Drupal 8 core. Let me know in the comments if you get stuck at any point, and I’ll be happy to help you out.

Share your opinion in the comment section. COMMENT NOW

Share This Article

Inshal Ali

Inshal is a Content Marketer at Cloudways. With background in computer science, skill of content and a whole lot of creativity, he helps business reach the sky and go beyond through content that speaks the language of their customers. Apart from work, you will see him mostly in some online games or on a football field.

×

Get Our Newsletter
Be the first to get the latest updates and tutorials.

Thankyou for Subscribing Us!

×

Webinar: How to Get 100% Scores on Core Web Vitals

Join Joe Williams & Aleksandar Savkovic on 29th of March, 2021.

Do you like what you read?

Get the Latest Updates

Share Your Feedback

Please insert Content

Thank you for your feedback!

Do you like what you read?

Get the Latest Updates

Share Your Feedback

Please insert Content

Thank you for your feedback!

Want to Experience the Cloudways Platform in Its Full Glory?

Take a FREE guided tour of Cloudways and see for yourself how easily you can manage your server & apps on the leading cloud-hosting platform.

Start my tour

CYBER WEEK SAVINGS

  • 0

    Days

  • 0

    Hours

  • 0

    Mints

  • 0

    Sec

GET OFFER

For 4 Months &
40 Free Migrations

For 4 Months &
40 Free Migrations

Upgrade Now