How I built my own blog.

3 December 2026, 9:45 am · 6 min read · programming, project
How I built my own blog.

Why build it at all

There are a hundred places where i could have just made a blog in five minutes. Sign up, pick a theme, type, done. But i keep coming back to the same thought i had when i built my mp3 player: if you only rent something, it can be taken away, or filled with ads, or changed whenever the company feels like it.

A small site that you own is worth more than a big one that you rent.

So i made one. This is the story of how, with the boring parts and the broken parts left in.

The rules i gave myself

  • No framework, no build step, no database. Just HTML, CSS and JavaScript.
  • Double click index.html and the site should open. Nothing to install.
  • Everything i would want to change lives in one settings file, so i never have to dig through code to fix a typo.
  • Quiet by default. No feeds, no popups, no noise.

What it is made of

The whole site is a handful of files in a GitHub repository.

FileWhat it does
index.htmlThe one page everything is shown on
content.jsMy settings: name, About text, links, banners, friends, changelog
posts.jsMy blog posts (the editor writes this one for me)
common.jsThe sidebar, dark mode and small helpers every page uses
site.jsThe home page, writing list, archive and the editor
pages.js and media.jsWishlist, gears, bookmarks, friends, and the anime, movies and books page
style.css and friendsHow it all looks

It is hosted on GitHub and my own domain, jeffnet.blog, points to it. That is the whole infrastructure. No server, no bill besides the domain.

How the pages work

The site is really one page that changes what it shows. The part of the address after the # decides which page you see, so #/about is the About page and #/writing is the list of posts. This is called a hash router, and the idea is tiny. Here is a simplified version:

js
window.addEventListener("hashchange", handleRoute);
        
        function handleRoute() {
          const page = location.hash.replace("#/", "").split("/")[0];
        
          if (page === "about") renderAbout();
          else if (page === "writing") renderWriting();
          // every new page is one more branch like this
        }

Blog posts are different. Each post is its own real HTML page, so you can share a link to one post and it just opens.

Writing posts

I wrote a small editor into the site itself (it is hidden, so only i know where it is). I type a post in a simple format, with ## for headings and - for bullets, and it shows a live preview next to it. When i press Publish, it sends the post to GitHub and the site updates in about a minute.

Later i added a few things to it:
- A table of contents that builds itself from my headings.
- Categories, so Writing has Personal, Tech and Review inside it.
- Code blocks with a Copy button, and tables. (You are looking at both right now.)
- Drafts that save themselves, so closing a tab never eats a post.

The pages, one by one

I did not plan all of this on day one. It grew one small idea at a time:
- Now: what i am up to, with a history of older snapshots.
- Changelog: every change to the site, written as a thread.
- Archive: every post in one place, by year.
- Friends and the guestbook.
- Bookmarks, a wishlist, gears, photos and art.
- A media page for anime, movies and books, which pulls my anime list from AniList and movie posters from TMDB.
- Comments on posts, kept as GitHub Discussions through giscus, so there is no comment database to run.
- A newsletter, a contact form and an RSS feed.
- Visit counts with GoatCounter, which uses no cookies and does not follow anyone around.

The music page that broke

This one deserves its own section. I wanted a page showing what i am listening to, so i used Last.fm. It worked, and then Last.fm started asking for a paid Pro plan just to use its API. I switched to ListenBrainz, which is free and open source, but the verification email never reached me for a while.

So the Music page sat there saying it was inactive, and i wrote that down in the changelog instead of pretending it was fine. Once my account was verified, i rebuilt the page on ListenBrainz. It needs no API key at all, only my username.

The doodles

Every page has a banner. They are all drawn in the same style: grey scribbly lines with red fills, a bit messy on purpose. I started with a few i drew myself, then made the rest of the set in the same style with Claude's help, because i wanted every page to have one and i did not want to spend a month drawing.I will later draw the ones again.

How i used Claude

I will be honest about this, because it is a blog about how it was made. Claude wrote few of the code. What i did was decide what the site should do, say what was wrong when something broke, test it on my own phone and computer, and keep saying "make it simpler". I knew what i wanted the site to feel like, and having something do the typing made that faster.

If you are curious, that is the same way i built my mp3 player.

What i learned

  • Start small. The first version was just a home page and a list of posts.
  • Keep all the settings in one file. Future me is lazy.
  • A changelog is a gift to yourself. I can see exactly when and why i broke something.
  • Things will break, and that is fine. Say so and fix it.
  • Check it on a phone. Half the people who visit will be on one.

What is next

  • A guestbook form for friends who do not have a GitHub account.
  • My own photos on the Photos page instead of pictures i saved from Pinterest.
  • More posts. Obviously.

If you spot a broken link or have an idea for the site, the guestbook and the contact page are open.

Thanks for reading. See you in the next one.

Back to all posts