Create Your Free Hugo Blog

· 305 words · 2 minute read

You can create a free blog more easily than you think.

There is a long list of popular static blog systems. If you ask me, the top options right now are GatsbyJS and Hugo.

Both are great. Today I’m talking about Hugo because it is less complex than GatsbyJS. Hugo is written in Go, and it’s extremely fast at building static pages. You can check the full list of features here.

To host it, we’ll use Netlify. It’s super easy to use and free.

First, create a Netlify account. We will need it to deploy our blog. Go to the dashboard and add a new site with CD (Continuous Deployment). When you upload a new change to your blog, Netlify will update the website automatically.

When creating the new site, choose your Git provider. Most people use GitHub or Bitbucket. Choose your repository and configure it. Check the image below, since you will need to provide a similar configuration. The chosen branch is the watched branch that will trigger deploys.

Netlify Hugo Configuration

Now you have to create the blog structure inside your repository. Open a terminal in the repository folder.

Install Hugo locally:

brew install hugo

Create a new site (choose a proper name):

hugo new site awesome-new-site

One of the most important pieces of your blog is the theme. Choose one and add it as a submodule to your repository:

git submodule add https://github.com/budparr/gohugo-theme-ananke.git themes/ananke
echo 'theme = "ananke"' >> config.toml

Once your Hugo blog is configured and has a theme, you can create new posts:

hugo new posts/my-first-post.md

Final step: upload the changes to the repository. Netlify will build and deploy it. Congratulations! Your blog is online.

I’m not explaining how to use your own domain, since Netlify has already done a good job with their guides.

If you get lost, check the Quick Start.