Find out whether only this computer is offline, then check airplane mode, reconnect Wi-Fi, restart the router, run the troubleshooter and reset the network.
The first thing to find out is whether the problem is only yours. If phones or other computers on the same Wi-Fi are offline too, the router or internet provider is at fault; if only this computer is, look at its settings.