How to Turn an Old Project Web Page into a Static Web

Story of Old Research Project Websites

Many academic and research projects create websites during their active phase. These sites serve as information hubs, showcasing research findings, datasets, publications, and related activities. However, once the project concludes, there is no further interest to update and maintain those websites as the project itself is not operating. Sometimes the site is quite meaningless but sometimes it is required to keep it alive for extended periods.

Reasons why these sites remain online but do not get updated:

A possible is converting the site into static HTML. This keeps the content accessible while eliminating the need for active maintenance or security updates.


Converting a WordPress Site to Static HTML

There are several ways to convert a WordPress site into a static version:

WordPress Plugins (Easy but Limited)

If your WordPress site is still operational, you can use a plugin like:

These plugins generate a static version of your site, which you can then upload to your hosting provider. However, if you have already moved away from WordPress or cannot access the admin panel, a better approach is to mirror the site and copy hard files to the web server as a static web page.


Using Wget to Convert a WordPress Site to Static HTML

wget is a command-line tool that can crawl and download entire websites, preserving structure and links.

Step-by-Step Guide to Using Wget for Static Site Conversion

1. Install Wget

Most Linux and macOS systems come with wget pre-installed. You can check by running:

wget --version

If it’s not installed, you can install it using:

2. Download the Entire Website

Navigate to an empty directory and run:

wget --mirror --convert-links --adjust-extension --page-requisites --no-parent https://yourwebsite.com/

Explanation of Flags:

3. Verify the Downloaded Files

Once the command finishes, navigate into the directory and check the downloaded site structure:

cd yourwebsite.com
ls -l

Open the site in a browser by opening the local index.html file.

4. Upload the Static Files to Your Server

Now that you have a local copy of your website, you need to upload it to your web server.

Option 1: Using cPanel File Manager
  1. Log in to cPanel.
  2. Go to File Manager and navigate to public_html.
  3. Delete or move the existing WordPress files.
  4. Upload the static files from wget.
Option 2: Using SCP or FTP

If you have SSH access, you can use scp:

scp -r yourwebsite.com/* user@yourserver:/var/www/html/

For FTP, use FileZilla or any FTP client to upload the files.

5. Test the Static Website


Final Thoughts

Converting an old project website into a static version is a good way to preserve it without worrying about maintenance, security risks, or software updates. Using wget is a simple and effective way to achieve this when the WordPress site is no longer actively managed.

Last but not least, with new static HTML version, the site will load faster, be more secure, and require zero upkeep. 🚀