Sometimes you have to change your hosting company and you do not want to pay for premium transfer plugins. In these cases, you must know how to change paths in the database to keep everything fine.

  1. Download your database file from phpMyAdmin
  2. Open the file with Notepad++
  3. Find and replace using this format:
    1. cPanel format: /home/accountname/public_html/
    2. DirectAdmin format: /home/accountname/domains/example.com/public_html/
    3. Plesk format: /var/www/vhosts/example.com/httpdocs/
  4. Save your file. Compress the file and upload it to your new host phpMyAdmin. (For DirectAdmin using .tar format is better. I strongly suggest 7-zip)

A real example:

Consider my website is vtuprovider.com and I am using DirectAdmin. Now I am going to migrate to a cPanel hosting company. Also consider my accountname in DirectAdmin is username and in new cPanel is username. I should open my database, find all “/home/username/domains/vtuprovider.com/public_html/” to “/home/username/public_html/”

(Note: If you are changing to new domain name, you must replace all domain names too. )

Originally posted on July 21, 2023 @ 9:12 pm

Leave a comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.