If you’re attempting to connect to Spotify while on a public WiFi hotspot, or while on a school or work network, the firewall may be blocking Spotify.
Public WiFi hotspots will block streaming services to preserve the available bandwidth for all users, while schools and places of employment will block streaming services to prevent students and employees from becoming diverted from the task at hand.