Skip to content

Comprehensive Development Services to Accelerate Business Growth

From CRM solutions to web, mobile, AI, and custom software development.
Migrate Your WordPress Site on Ubuntu

Manually Migrate Your WordPress Site on Ubuntu: A step-by-step Guide

Securely move your WordPress website to a new Ubuntu server with this step-by-step guide. Learn to transfer files, themes, plugins manually

Editorial Team

Introduction:

Imagine your WordPress website getting hacked. Cyberattacks can steal data, damage your reputation, and put your site at risk. To avoid data loss, it’s important to keep your files, content, media, and plugins safe. Manually migrating your website is a reliable way to move everything while keeping your themes and data intact. This method helps you transfer your site to a new directory or server without relying on automated tools.

Manual migration also gives you full control over files and databases, ensuring everything is set up as needed. However, moving a WordPress site to a live Ubuntu server can be challenging for beginners. In this guide, we’ll walk you through the step-by-step process of migrating your WordPress website using command lines.

Here are the Ubuntu commands to copy the necessary files from your old WordPress directory (outrightsystems.org-20feb) to the new one (outrightsystems.org). Let’s get started!

Step 1: Navigate to Your Web Root Directory

First, open your terminal and go to the root directory where the WordPress installation is located. Most WordPress installations are located in /var/www/html/, but examine and adjust accordingly if your setup is different.

cd /var/www/html/

Step 2: Copy the Active Theme

The theme controls the website design and layout—transferring it properly is crucial to maintaining the same look of your website. Run the following command to copy your entire themes folder:

cp -r outrightsystems.org-20feb/wp-content/themes/your-theme-folder
outrightsystems.org/wp-content/themes/

Once the file is copied, make sure they have the correct permissions to ensure smooth workflow:

chown -R www-data:www-data outrightsystems.org/wp-content/themes/your-theme-folder
chmod -R 755 outrightsystems.org/wp-content/themes/your-theme-folder

Step 3: Copy Uploaded Media Files (Icons & Images)

To migrate all uploads, use the following command to prevent broken images on your website:

Now, set the correct permissions:

Step 4: Copy Plugins (If Needed)

Plugins add new features and functionality to your WordPress website, eliminating the need for code modification. Move plugins using the following command. 

Then, fix permissions:

Step 5: Copy wp-config.php (Manually)

Related walkthrough

Top 10 Must-Have WordPress Plugins for Beginners

Practical guidance from the Outright Systems team. Watch on YouTube

Do not copy wp-config.php directly from the old installation. Instead, open both files in the editor and copy necessary configurations manually:

Copy only essential settings like database configurations, security salts, or cache settings that need to be mitigated.

Step 6: Copy .htaccess (Manually)

Similar to wp-config.php, do not copy .htaccess directly—this file contains rukes for redirects, permalinks, and security. Instead, compare and copy specific settings manually:

Step 7: Fix File Ownership & Permissions

After all files are copied, ensure they have the correct ownership and permissions to avoid any issues:

Step 8: Restart Web Server

Restart your web server depending on which server you are using, such as Apache or Nginx.

For Apache:

For Nginx:

Step 9: Verify Everything

Now all the things are done—monitor and recheck everything is working correctly, and ensure your new WordPress is installed correctly. 

💠Log in to your new WordPress admin panel.
💠Go to Appearance > Themes and check if your theme appears.
💠Go to Media Library and confirm images are visible.
💠Go to Plugins and activate the necessary plugins.

Finishing Up

Unlike traditional tools, mitigating your WordPress website manually might take more effort—but this allows you to control and monitor the overall process. This guide has everything you need to know about migrating a WordPress site to a live Ubuntu server. Following these steps will ensure that your website’s theme, media files, and plugins are transferred correctly—ensuring a smooth working process and reducing errors.

Article rating

Was this article useful?

0.0 out of 5 from 0 ratings

Discover our most-read articles, packed with expert insights, practical tips, and industry-leading knowledge.

Need Answers Before You Get Started?

Clear answers about custom CRM, integrations, automation, and support.

  1. We offer Custom CRM Development, CRM Consulting, and CRM Development Services, including SuiteCRM Development, SugarCRM Development, and CRM Customization Services.

Let's stay in touch!

We'll send you a newsletter once per week. No spam.