In the early days of the modern web - say, the mid-1990s through the mid-00s - my personal website was served statically. It was built with plain HTML (CSS didn’t exist at the time) that I copied and pasted when I needed to create a new entry (the word blog didn’t exist then either).
But then databases happened. I remember powering early versions of my web projects using a Microsoft Access database, an ODBC connection, Active Server Pages (ASP). It then became quite normal to rely on serving websites using databases - even for content that would seldom change.
In a way, I think this was a huge mistake of the early web or, more specifically, of the early web developer community. We should have doubled down on creating platforms and services that served static HTML websites but, instead, we went all in on databases. It wasn’t until we had server-side caching mechanisms that we kinda/sorta went back to serving static pages to our visitors. But that was mostly created to keep things fast at scale. It made websites more complex not less.
As the decades passed I didn’t think twice about serving millions and millions of page views using dynamically created pages. Each visit requesting a computer to search through a database for all the content I needed to be displayed on the page. It was fast, I thought, so who cares? Who cares of the website was overly complex or had a bunch of moving parts that required maintenance, security patches, and used an enormous amount of electricity?
But today, now that I have Tuff and my personal website is served statically, as is my side hustle, and my new fun project, and my little word game — I've fallen back in love with serving sites statically. Why would a mostly unchanging website need to be constantly requesting information from a database? Sure, caching. But why deal with that complexity at all if it isn’t needed? All of my sites are fast. And cheap! And simple. I love it.
Most of my personal websites these days do not get a lot of traffic. Professionally I’ve worked on projects that require scaling to thousands of requests per second. But none of my personal projects require that. So why not keep it simple? Why not keep the requirements to a bare minimum? Why not keep the costs low?
So I'm slowly moving all of my projects to a single instance with far less requirements, less software to keep up-to-date, no databases, and static files.
From now on I’m starting new projects in the opposite direction. Static first, dynamic second.