I've always used Apache as webserver, just because that's what I'm used to.
It seems that Nginx is now (by far?) the most popular server. Is there any particular reason why it's become so popular? What's the main advantage over Apache?

@mogwai Nginx is faster and has something called a "reverse proxy"? also I found this website that might help you in deciding the best web server for you 😁

@rsheftel @mogwai To be honest I have no idea what that is 😅 I just read it from there website a long time ago

@0PT41N Thanks, I'll have a look at that site!

Apache can also do reverse proxy. I have several services set up like that. But maybe Nginx had that functionality earlier?

@mogwai When I am working with web servers my top 3 would be.🤔
1. Nginx
2. Lighttpd
3. Apache


> Is there any particular reason why [nginx has] become so popular? What's the main advantage over Apache?

My (potentially hot?) take is that you've stuck with Apache long enough that it's back to being a good option. There was a pretty good while when nginx was *dramatically* faster (esp. for static content) and easier to use modularly — but I believe Apache has now pretty much caught up. See

(That said, I've always used nginx without any real complaints)

@codesections @mogwai Yeah, I stick to Apache because I'm old and set in my ways, and it still works fine.

There are some issues with new plugins, but I know it well enough to fix every problem so far.

@mdhughes @codesections @mogwai The only real "problem" I've run into with Apache is that if you're doing WSGI it's compiled against a single version of Python. I'll use nginx now mostly so as not to be "that guy," though over here in Go-land I don't really need to care about either of them.

@codesections @mogwai I suspect this is true. It’s been a long while since I used Apache, but I think I remember the nginx docs being a lot easier to read.

@IslandUsurper @codesections Yeah, I wouldn't be surprised that Nginx has better documentation.

It's been a long time since I looked at the Apache documentation in detail. I remember it wasn't that clear. I usually use the Arch wiki for the basic Apache setup.

@codesections Thanks!

That could definitely make sense. I mainly use webservers for small-scale personal stuff where I'm mostly not that interested in performance.

(Ironically, that's probably the kind of projects where you could see the largest benefits. 😀)

@mogwai I found Apache very unstable on single board computers with not much RAM. I spent a lot of time trying to tweak webserver parameters so as not to run out of memory, but in the end Nginx worked far better.

My guess is that Apache was designed for large deployments on systems where there are few resource constraints.

@bob Probably, yes.
Apache feels like a big "monster" sometimes.
I haven't tried it on an SBC, yet. And hearing you, I probably won't try it. (Or at least I'll be very cautious.)

@mogwai Personally I use nginx to serve my personal siteS on my personal server!

I find it quite easy to configure, but I haven't compared the two.

@mogwai Apache's config format is weird and inconsistent. support for running applications in-process has caused Apache to be more complex, but nginx's proxy-only approach allows it to focus on doing just one thing well.

@mogwai it started with Ruby on rails. It was better to run on nginx. Then it stuck around and got better.

@mogwai not having to write XML config is very compelling.

Also I've never been able to get websocket proxying to work in apache but it's like 1 line in nginx and actually works.

@mogwai when looking for my first web server/reverse proxy, Nginx's configuration syntax was a lot less scary

@mogwai It does not have .htaccess files - all config is in one location.

It's event based rather than using threads or processes, and thus requires less resources.

Also it's not associated with the Apache Software Foundation, which is a plus on its own. #LibreOffice

Sign in to participate in the conversation

Fosstodon is an English speaking Mastodon instance that is open to anyone who is interested in technology; particularly free & open source software.