MacBook can’t connect to hotel internet

I have an old Mac notebook that I use for surfing the internet or to store and upload photos while on trips. While travelling around this summer I found that it would no longer connect to any hotel’s wifi network. The first night I assumed it was something about the hotel’s network, but when it happened in a different hotel the second night, I realized something had changed in the Macbook’s settings.

My iPhone had no problem connecting, which really made it clear there was something wrong on the Macbook end of things. When I checked the Network Diagnostics, it showed that airport had connected to the hotel wifi networks, but Safari would never redirect to the hotel’s network login page. The Network status screen showed Airport and Network settings as “green” but everything else red or yellow, including ISP, Internet and Server.

After many searches and settings adjustments I realized it was something really simple: at some point the laptop’s firewall had put up a request to approve or deny some connection, and I must have accidentally denied it. Shutting off the firewall temporarily fixed the problem instantly:

System Preferences > Security > Allow all incoming connections