How to create a STATIC website from Wordpress

Thought about getting out of Wordpress and creating a much faster, safer, robust website — check this review of static file generators and solutions for Wordpress.

These ‘tools’ will (or attempt to…) create a static version of your Wordpress website. Some will work on a page and some on a whole website. They are generally Wordpress Plugins as opposed to tools that run from the command line*.

How do they differ from tools such as cUrl or wGet (my two favourite site download tools). Well I will try to compare and use these two tools as well — just for comparison purposes. cUrl and wGet tend to run from the command line and will download ANY website. The main tools used here proclaim to create static pages from Wordpress only.

All information is taken from October 2017, so number of active installs and other information is only relevant at that date. A lot of these type of plugins are NOT actively used or maintained, but can be useful.


Plugins tested (or being tested…)

  • Simply Static
  • WP Static HTML Output
  • Really Static
  • Static Press

Testing

To test the effectiveness of these tools I will have:

Scenario 1

  • a standard installation of wordpress
  • 1 post and 1 page.
  • No additional plugins
  • No page builder installed

Scenario 2

  • a standard installation of wordpress
  • 1 post, 1 page and 1 custom post type
  • A few standard plugins (slider, SEO tool, etc.)
  • Standard free page builder

Simply Static

Simply static plugin to create static websites from wordpress.

Ok, first review — Simply Static. I really think I may of found the ‘best’ free static Wordpress generator first in my list! Anyway from a default website with just Jetpack and DIVI installed, I also have a post and a page.

Setup some parameters in the setup (under settings) and pressed the ‘Generate’ option.

Was a bit slow to kick off, but after about 30 seconds it had done its job. A ZIP file is created and ready for me to download :)

Running Generate option

Output from Simply Generate — static file generator for Wordpress

I downloaded the ZIP file. Unzipped the file into a localhost setup (typical WAMP setup), and entered my localhost url — not good… Should of looked at the setup more carefully!

So if you are creating static pages from your Wordpress you FIRST need to think about the destination url structure (obvious really). In my case I was putting the static files onto:

localhost/static/simplystatic/

So… I popped into the settings, added this as the destination url (relative urls option)

Setting up the destination url structure for simply static

Re-running the ‘generate’ option. Got the ZIP file, popped it into the localhost url and UnZipped the files. Didn’t do anything else on the basis that I would see what happens.

To my surprise it was remarkably good. All the pages had the correct link ups to the CSS and JS files in the correct folders

Folders created when running Simpy static from basic Wordpress site

Observations

  • grouping stuff like ‘categories’, and ‘authors’, dates for archives, etc. all created separate index.html files to take care of those links.
  • wp-* folders were created with just the relevant stuff in them (mostly css and js files)
  • Post titles were created as folders with structures (see above ‘this-is-the-title’ post) — again with the correct index.html file created within that folder.
  • Comments folder has a ‘feed’ folder and index.html with the content being an XML feed (nice touch)
  • Category folder — has sub folders, one for each category and an index.html file in each folder and a feed subfolder, holding the correct index.html feed XML file.
  • wp-admin / index.html holds a redirect to the online login page.
  • wp-content / files hold the themes, plugins and cache (if your using a cache). Again the files transferred tend to be just images and CSS files to make the site still work correctly.
  • A folder called wp-json is created with a large index.html file. This file is a large json structure the with site in it. Perhaps useful for further processing…?

Conclusions

  • Static generators from Wordpress have a VERY hard job to do… they will have to contend with Plugins, themes, hacker code, functions.php issues, paths and non-relative paths, image locations, internal linking schemes, feeds, plus a tonne of other stuff. Well done to this guy (Scott I think). He’s done a great job of getting something going that seems to work ‘ish.
  • I even pushed it by using the DIVI page builder to create a page with Content, CTA and Tabs modules with columns. No problem — all came across nicely
  • Tried to see if the site was still ‘responsive’ — yep no problem. Hamburger menu appears nicely for mobile, and the columns and other elements re-adjust just fine :)
  • Early days. Judging by Scott’s website (very basic site — http://www.codeofconduct.co/) — he’s started. His last post on the site was October 2016 and not sure if much has happened since. But what I have seen from this guy is really encouraging.
Last blog from Scott’s website…
  • Does it tackle moving people off Wordpress into more static sites? Or is it a useful tool to use to just get content out and being able to repurpose using other tools — time will tell. I will do some more tests and report back!

WP Static HTML Output