So this a very annoying issue that wheneve you open spotify and try to play a track it says “Please disable offline Mode and try again”. Even though you’re online and every other website or service works, you’re still stuck at that error.
After searching the internet for a solution, you’ll get no solution or workaround to tackle the issue. Fortunately I could find a reason and solution for this issue. At last, the poor Spotify was right, although it could give us better details to pinpoint the problem. The thing is, it’s most likely your DNS servers are down and windows or whatever OS you’re using is utilizing it’s DNS resolver cache. This makes spotify app to be unable to get it’s servers IP addresses. the solution is that you should use another DNS resolver service like Google’s 126.96.36.199 or Quad9’s 188.8.131.52.
Another cause is Virtualbox’s network adapters. Once disabled, it seems the problem is gone. So try that as well.