I’ve been using Nginx for about a decade, and beyond using Varnish every now and then I haven’t really had the need to use anything else. Well, recently I started trying out Caddy – in fact, this site is served using Caddy.
Would you consider trying Caddy or just stick with Nginx? Let me know in the comments.
So, how does it compare? Well, I haven’t seen any benchmarks of Caddy 2 where performance wasn’t better than Nginx. In my less synthetic testing, Caddy has performed great either way.
The configuration files can be way way shorter compared to Nginx. It can also fetch SSL-certs by itself and in general the SSL setup is great straight out of the box. Oh, Caddy also has an API – that’s pretty cool, although I haven’t used it much myself since I handle changes in other ways.
Any con’s you ask? Well yes, there are. No built in caching, and the caching plugin hasn’t been updated for v2. No rate limiting solutions built in either.
A simple WordPress config
Here is an example of what a Caddyfile for WordPress could look like. I think it is pretty self explanatory.