Simple, efficient and elegant dev.

The 4 Reasons Why I Prefer Eleventy Over Other SSGs

Last edition :

Table of contains

In this article, I’ll share why I chose the static site generator (SSG) Eleventy over more well-known generators like Hugo, Gatsby, Astro, or Jekyll for creating my blog.

Note: I’m not claiming that Eleventy is better than other SSGs. That would be like saying an apple is better than a pear, strawberry, cherry, or apricot. Each tool has its own characteristics, and each user has their own criteria for choosing.

Important

The most important thing is to be clear about the criteria that matter most to you and to find the tool that best fits. That’s why I’ll share my own criteria and how Eleventy meets them.

The Criteria That Led Me to Choose Eleventy

My criteria are shaped by the frameworks and languages I already know and my natural preference for simplicity and lightness. I wanted an SSG that:

Requires learning few new things. As someone specialized in ASP.Net/Blazor for web development, I’m comfortable with vanilla HTML/CSS/JS but don’t master classic web frameworks like Angular, React, Vue, or Svelte, and I don’t have time to learn them.

With Eleventy, I only had to learn the Nunjucks templating language, which was very quick—probably 100 times faster than if I’d had to learn React, for example.

Has a lightweight technical environment, meaning little to install.

Eleventy relies on Node.js and doesn’t require any other specific installations. It provides its own lightweight web server. So, you just need to know how to initialize a Node project and the basics of npm and the package.json file to generate the site and run the local server. But the documentation guides you through this.

Allows writing blog posts in Markdown.

Eleventy uses the markdown-it engine to handle Markdown. It’s arguably the most popular and comes with extensions for advanced syntax elements like GitHub alert blocks, anchors, etc. What more could you ask for?

Allows complete customization of your site.

Eleventy is very versatile and flexible, letting you customize everything. To go faster, you can draw inspiration from templates close to what you want to do. However, for my blog, I struggled to find such a template and ended up adapting the basic "Eleventy base blog" template, which I barely kept anything from in the end 😊.

Fast (I’m talking about the speed of generating the site from template files, CSS, and images). Since you’ll be generating the site often, it’s important for this operation to be quick.

Eleventy is the speed champion, thanks to its lightness. Unlike other tools like Vite, Webpack, etc., it does fewer things, and that makes it much faster.

Well-documented enough.

Eleventy’s documentation is the only point I find rather mediocre, though not outright bad. I’ll come back to this later...

Popular enough to ensure its longevity.

Eleventy isn’t the most popular SSG if you look at, say, GitHub stars. It currently has 18k stars compared to 51k for Astro and 56k for Gatsby. But it’s clearly popular and well-established enough to have a very good chance of lasting.

Areas for Improvement

I’m really super satisfied with Eleventy and have almost no complaints about the tool itself. However, I see three major improvements for the Eleventy website that, in my opinion, could significantly increase the tool’s adoption:

Improve the documentation, which currently lacks context.
Many techniques are presented without their use cases, with overly basic examples. As a result, when you’re starting out, it’s hard to know when to use one technique over another. I had to do a lot of trial and error to deeply understand certain concepts and use them effectively. But on the bright side, I now have plenty to share on my blog 😉!

Note: As a trainer, I know I set the bar high for documentation because it’s my specialty. I’ve written thousands of pages of docs and articles and created hundreds of videos, mostly for beginners. So, naturally, I’m sharp and demanding on this topic...

Make it easier to select a project template. The Starter Projects page, which lists the 170 available project templates to date, offers no way to filter the list, and the template descriptions are very brief. It’s very hard to find a template that matches your needs. Not to mention that some templates are outdated because they were created with older versions of Eleventy...

Improve the official base template. I think the "Eleventy Base Blog" template provided by Zach Leaderman is of rather mediocre quality:

When Should You Use Eleventy?

To summarize, if you’re still wondering whether Eleventy would suit your needs, here are the factors to consider.

First, it’s important to clearly understand the characteristics of a static site compared to a dynamic one.

A static site is an excellent solution if...

You want a completely free solution (including hosting if you use, for example, GitHub Pages).

You want to create a secure website, but implementing security techniques bores you. So, you want an effective but easy-to-implement solution.

You have few customer data to store on the server side, and you are ready to use external APIs for that.

You prefer customizing your site directly with HTML, CSS, and JavaScript code rather than through plugins (like in WordPress).

You want to write your blog posts in Markdown in your favorite editor (e.g. Obsidian)

You like to have complete control over your site (structure, appearance, performance, SEO...), without unnecessary complexity.

You want to create your site locally and deploy it easily to a server by changing its base URL.

Note

For more details on static sites and their differences from dynamic ones, check out this article.

If you’ve decided to create a static site, why choose Eleventy over another SSG?

Eleventy is THE SSG for you if...

You particularly appreciate lightness and simplicity, and don't want to have to install and master loads of tools.

You need a fast SSG (I'm talking here about the speed of generating site pages from source files), especially if you often generate your site.

You want a simple, high-performance solution for managing your images and icons.

You don't want to depend on any particular JavaScript or CSS framework.


Note that Eleventy can generate all the types of static sites listed in my previous article :

What about you? Do you use or plan to use an SSG? If so, what criteria guide your choice? Let me know in the comments.