---
title: "Discussion on \"After 4 years with nginx, we switched to Caddy - Here is why\" | Hashnode"
description: "Discussion on \"After 4 years with nginx, we switched to Caddy - Here is why\". When we started Hashnode in 2015, we wanted to keep things really simple. Since nginx was the most popular choice, we decided to use it as a reverse proxy to our Node.js backend. It was a simple set up and worked really well for us for years. \nWith D..."
url: "https://hashnode.com/posts/after-4-years-with-nginx-we-switched-to-caddy-here-is-why/5d12263af490ff005379ebff"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [After 4 years with nginx, we switched to Caddy - Here is why](https://engineering.hashnode.com/after-4-years-with-nginx-we-switched-to-caddy-here-is-why?utm_source=hashnode&utm_medium=feed)

When we started Hashnode in 2015, we wanted to keep things really simple. Since nginx was the most popular choice, we decided to use it as a reverse proxy to our Node.js backend. It was a simple set up and worked really well for us for years. With D...

Jun 25, 2019 · 5 min read · engineering.hashnode.com  
Updated Nov 2, 2021  
Read the article

-   [#programming](https://hashnode.com/tag/programming)
-   [#hashnode](https://hashnode.com/tag/hashnode)
-   [#nginx](https://hashnode.com/tag/nginx)

## Written by

[Sandeep Panda](https://hashnode.com/@sandeep)

@sandeep · Bangalore

  
[View profile](https://hashnode.com/@sandeep)

co-founder, Hashnode

I am the Co-Founder of Hashnode. I write (about) code and keep interest in Venture Funding and startups. Feel free to contact me at sandeep@hashnode.com.

## Responses 8

Markdown supported · ⌘↵ to post

[Af](https://hashnode.com/@Af)

[May 19, 2021](https://hashnode.com/posts/after-4-years-with-nginx-we-switched-to-caddy-here-is-why/5d12263af490ff005379ebff/comment/60a4ea155c1fcb4077364cf8)

Amazing stuff dude. Every insightful stuff.

I am currently working on project to do similar thing to yours.

I am currently on aw and use alb, how do you cover load balancing between ecs containers.

[Yashu Mittal](https://hashnode.com/@mittalyashu)

[Nov 12, 2019](https://hashnode.com/posts/after-4-years-with-nginx-we-switched-to-caddy-here-is-why/5d12263af490ff005379ebff/comment/5dca2526413a6c7077839e16)

Caddy team is working on v2, so are you guys planning to migrate to v2

Once done, please share your thoughts and process for the same.

[Raghavan alias Saravanan Muthu](https://hashnode.com/@itsraghz)

[Oct 20, 2019](https://hashnode.com/posts/after-4-years-with-nginx-we-switched-to-caddy-here-is-why/5d12263af490ff005379ebff/comment/5dabec3e4573b57b0bb32890)

Hey Sandeep, looks very interesting on the stats. Have been obsessed with Apache and kinda hearing more about Nginx replacing Apache. now yet another buddy in this list - Caddy!

Thanks for sharing your experiences along with the features and benefits of Caddy Server. Sure, will check this out.

[Gijo Varghese](https://hashnode.com/@gijovarghese)

[Jul 1, 2019](https://hashnode.com/posts/after-4-years-with-nginx-we-switched-to-caddy-here-is-why/5d12263af490ff005379ebff/comment/5d1a0900d1bf28a0475bac11)

Awesome article!

So caddy server acts a a cache layer that caches html pages, right? How do you clear caddy server cache if a particular page is updated?

[Sandeep Panda](https://hashnode.com/@sandeep)

[Jul 10, 2019](https://hashnode.com/posts/after-4-years-with-nginx-we-switched-to-caddy-here-is-why/5d12263af490ff005379ebff/comment/5d1a0900d1bf28a0475bac11#reply-5d25c8c2696097e87c7a8c42)

Sorry about the delay. I took a short break and didn't have a chance to go through the comments.

When any post is updated, we send a message to each of the edge nodes via rabbitmq and simply delete the `.html` file from the disk. That takes care of the cache purging.

[Gijo Varghese](https://hashnode.com/@gijovarghese)

[Jul 10, 2019](https://hashnode.com/posts/after-4-years-with-nginx-we-switched-to-caddy-here-is-why/5d12263af490ff005379ebff/comment/5d1a0900d1bf28a0475bac11#reply-5d25d6a15d5a5a0231f50dc1)

[Sandeep Panda](https://hashnode.com/@sandeep) so it clear entire HTML files? Edit in your blog post shouldn't clear cache from other user's right?

[Serdar Sanri](https://hashnode.com/@ssanri)

[Jun 26, 2019](https://hashnode.com/posts/after-4-years-with-nginx-we-switched-to-caddy-here-is-why/5d12263af490ff005379ebff/comment/5d13878e31885afb5c4560bb)

This is really interesting Sandeep. I am working on a side project kinda have same concept ( multi tenants have their own domain under same application) and this issue has been in my mind once it is in production. Locally I use docker with nginx-proxy lets encrypt companion container and been PIA for some time. I will definitely keep this post in my favs.

[alin debian](https://hashnode.com/@alindebian)

[Jun 25, 2019](https://hashnode.com/posts/after-4-years-with-nginx-we-switched-to-caddy-here-is-why/5d12263af490ff005379ebff/comment/5d127d0edfeb7b210eb1c07e)

Very usefull story. Thanks for it!

[Michaela Greiler](https://hashnode.com/@mgreiler)

[Jun 25, 2019](https://hashnode.com/posts/after-4-years-with-nginx-we-switched-to-caddy-here-is-why/5d12263af490ff005379ebff/comment/5d127abadfeb7b210eb1c06c)

Very interesting insights. Thanks for sharing, I definitely learned something new!
