If you have removed a website from your hosting plan and wish to bring it back, you can restore it from the latest backup by following the steps below:
Step 1 - Re-Add Your Domain
Add the deleted domain to your hosting plan once more. Navigate to Websites and select Add website:
When prompted, select Skip, create an empty website:
Next, provide the required information and enter your domain name. Ensure that the domain name is active and accurately spelled.
If your website was on a subdomain and the domain is already added, create the subdomain again.
Step 2- Restore Files From Backups
Navigate to Websites and search for Backups on the left sidebar. Once there, select Files backups:
Choose the preferred date from the list. On the file area, open the domains directory, select the folder named after the website you want to restore and click on Restore files. The restoration process can take up to 15 minutes, depending on the size of your website.
Step 3- Restore the Database From Backups
To restore the database, you will need to create a new database and then restore the database backup.
Re-Create the Database
Create an empty database with the same name, username, and password as the previous one. To find this information, use the File Manager to open the configuration file located in the root folder of the restored website
For domains - the domain.tld/public_html folder
For subdomains - domain.tld/public_html/subdomain folder
Replacing domain.tld and subdomain with the name of your domain and subdomain.
Navigate to Websites → Manage, and search for Database Management on the sidebar:
Select the website on the left drop-down menu. Then, head to the Create a New MySQL Database And Database User section, enter the database name, username, and password from your website's configuration file and click on Create.
Restore the Database
Navigate to Websites → Backups and select Database backups:
Choose the database name from the list, select the same backup date as the files backup, and click on Restore.
That's it! Your website is now restored. To verify it, open it using an incognito window on your browser.
Step 4 (Optional) - Restore Emails
If you have removed the website less than 7 days ago, you can recover your emails by following the procedure detailed on this article: How to Restore a Deleted Hostinger Email Account