Fix: Spotify Error Code 4 Connection Error in Windows 10 / 11

Undoubtedly, encountering Spotify error code 4 can be quite frustrating for Spotify users. 

This common problem prevents users from enjoying their favorite tracks on Windows 10 and 11.

The puzzling part? You get an error message stating “No internet connection detected”, even though you are perfectly able to browse websites.

What causes the Spotify Error Code 4 error?

Miscommunication between the application and your Internet connectivity settings is typically the cause of this issue.

DNS cache buildups often contribute to this scenario by hindering communication between Spotify servers and your device, leading to a streaming music error. Occasionally, the culprit could also be misconfigured proxy settings within the Spotify app itself that need troubleshooting.

Sometimes your computer’s default DNS server might not be recognized by Spotify or fails altogether.

External elements such as antivirus software or Windows Defender Firewall may negatively interact with internet connectivity leading to these errors. Changing your DNS server configurations can help circumvent some of these issues – specifically setting it up for Google’s DNS addresses – (preferred) and

Quick Fixes:

1. Flush DNS Command To Flush Your IP

This process involves several simple steps:

  1. Launch Command Prompt as an administrator on your computer.
  2. Input the command: ipconfig /flushdns
  3. Press Enter.

flush dns

2. Change DNS Settings

This method has proven effective for many users and involves switching your PC’s default DNS settings, predetermined by your ISP, to Google DNS.

Changing DNS has pretty much solved this issue for 85% of our clients!

Here are the steps you need to follow:

  1. Open “Control Panel” on your device.
  2. Navigate to “Network and Internet” > “Network and Sharing Center”.
  3. On the left-hand menu, select “Change adapter settings”.
  4. Right-click on your active network and choose “Properties”.
  5. Scroll down until you find “Internet Protocol Version 4 (TCP/IPv4)” and click on it.
  6. Choose the option titled “Use the following DNS server addresses”.
  7. Input Google’s Preferred DNS server as and its Alternate DNS Server as respectively.
  8. Click “OK” to save changes.

If that doesn’t fix the Spotify error, move on to the next step.

3. Choose the HTTP Option in Spotify

Here’s how to go about it:

  1. Launch Spotify and click on your username at the top right corner of the screen.
  2. Select “Settings” from the drop-down menu.
  3. Scroll down and click on “Show Advanced Settings.”
  4. Within these settings, look for ‘Proxy Type’.
  5. By default, this is set to “Auto Detect,” which could be causing connectivity issues.
  6. Changing it to HTTP has been reported to help mitigate Spotify Error Code 4.
  7. Once you’ve selected HTTP, don’t forget to click on “Update Proxy” to save your changes.

4. Exclude Spotify From Your Antivirus Software

 Antivirus programs can sometimes interfere with Spotify’s internet connectivity, causing this error.

Here’s how you can do it:

  • Open your antivirus software and go to the settings or options menu.
  • Look for the section related to real-time protection or firewall settings.
  • Add Spotify to the exception list or trusted software.
  • Save the changes and restart both Spotify and your computer.

5. Turn Off the Windows Firewall

Has Windows Firewall Blocked Spotify?

The Windows Defender Firewall can sometimes interfere with Spotify’s internet connection.

To resolve this issue, follow these steps:

  1. Open the Control Panel by searching for it in the Start menu.
  2. Click on “System and Security” and then select “Windows Defender Firewall.”
  3. On the window’s left side, click “Turn Windows Defender Firewall on or off.”
  4. Select the option to turn off the firewall for both private and public networks.
  5. Click OK to save the changes.

6. Allow Spotify through Windows Firewall

This step ensures that Spotify can establish a secure connection and internet access without any restrictions.

Follow these steps to Unblock Spotify and allow it through the firewall:

  1. Open the Windows Start Menu and search for “Windows Security.”
  2. Click on “Windows Security” to open the Windows Security app.
  3. In the Windows Security app, click on “Firewall & network protection.”
  4. Click on “Allow an app through firewall” or “Allow an app or feature through Windows Defender Firewall.”
  5. Click on the “Change settings” button (You may need administrator privileges to make changes).
  6. Scroll down until you find Spotify in the list of applications.
  7. Check both boxes next to Spotify (Private and Public) to allow it through the firewall.
  8. If you don’t see Spotify in the list, click on the “Allow another app” or “Allow another program” button.
  9. Select Spotify from your files or search for it in the list of installed applications.
  10. After selecting Spotify, click on the “Add” button to add it to the allowed apps list.
  11. Once added, click on OK to save the changes and exit the Firewall settings.

7. Restart the Devices

 This simple step can often fix connectivity problems and refresh the internet connection. Here’s how you can do it:

  • Turn off your computer or mobile device.
  • Unplug your modem/router from the power source.
  • Wait for about 30 seconds.
  • Plug in the modem/router again and turn it on.
  • Start your computer or mobile device.

8. Make sure Wi-Fi is turned on.

 A disabled or disconnected Wi-Fi connection can also cause the error to occur.

Here are some steps to ensure your Wi-Fi is enabled:

  • Check if the Wi-Fi icon is visible in your device’s taskbar or system tray.
  • If it’s not visible, go to the network settings on your device and locate the Wi-Fi option.
  • Make sure it is toggled on or enabled.
  • On Windows, you can find this by clicking on the network icon in the bottom-right corner of the screen and selecting “Network & Internet settings.”
  • On Mac, click on the Apple menu, go to “System Preferences,” then select “Network.”
  • Look for the Wi-Fi option and ensure it is turned on.

9. Connect to a different Wi-Fi network

Here’s what you can do:

  • Check if any other Wi-Fi networks are available in your area.
  • Connect your device to a different Wi-Fi network.
  • Ensure that the new network has a stable internet connection.
  • Spotify will automatically connect once it detects an internet connection

10. Update the Devices

Updating your devices is essential.

Ensure that all your devices, including your computer and smartphone, have the latest software updates installed. This helps in resolving any compatibility issues and ensures a smooth streaming experience. Keep in mind the following:

  • Regularly check for software updates on your desktop’s operating system (such as Windows) and update to the latest version available.
  • On your smartphone or tablet, go to the settings menu and check for system updates.
  • Install any pending updates to keep your device up to date.
  • Also make sure you have the latest version of Spotify on all your devices.

11. Modify the Registry


Here’s how:

  • Open the Start menu and type “regedit” in the search bar.
  • Click on the “Registry Editor” app to open it.
  • In the Registry Editor, navigate to the following location:
  • Look for a DWORD value called “EnableActiveProbing”.
  • If this value doesn’t exist, right-click on an empty space in the right pane and select “New > DWORD (32-bit) Value”. Name it “EnableActiveProbing”.
  • Double-click on “EnableActiveProbing” and set its value to 1.
  • Close the Registry Editor and restart your computer.

12. Reinstall Spotify

If you’re experiencing Spotify error code 4reinstalling the app can often resolve the issue. Here are the steps to reinstall Spotify:

  1. Uninstall Spotify from your device.
  2. Go to the official Spotify website and download the latest version of the app for your operating system.
  3. Once downloaded, open the installation file and follow the on-screen prompts to reinstall Spotify.
  4. After the installation is complete, launch the app and log in with your Spotify credentials.
  5. Try accessing your music library or streaming music to see if error 4 has been resolved.

Please be aware that if you reinstall the application, your Spotify playlists will be erased. Make sure to back up (export) any playlists that you want to keep so that you can restore them later.

13. Try Different Spotify Players

If the above-mentioned solutions still do not fix the problem, you can attempt to resolve it by changing to the web player or using the Spotify mobile application. 

Spotify utilizes port 4070 for establishing connections with its servers. In case this port is blocked and you are experiencing difficulties in running the Spotify desktop application, switch to the Spotify web player.

This will guarantee that only ports 443 and 80, which are associated with HTTP, are employed for establishing the connection. 

Also see: Troubleshoot issues with Spotify Web Player


1. Why am I experiencing Spotify Error Code 4 frequently?

Experiencing frequent occurrences of Spotify Error Code 4 could indicate underlying network issues in your area or problems with your device’s connectivity settings. It is also possible that there might be temporary disruptions in Spotify’s servers. If this problem persists, it is recommended to reach out to your internet service provider (ISP) for assistance.

2. Is there a way to prevent future instances of Spotify Error Code 4?

While occasional errors like Spotify Error Code 4 are difficult to completely prevent, there are a few measures you can take:

– Ensure a stable internet connection by connecting through a reliable network or switching ISPs if necessary.

– Keep your devices and apps updated with their latest versions as updates often include bug fixes and improvements.

– Avoid using VPNs or proxies while using Spotify.

Q: What should I do if I have no internet connection on Spotify?

A: If you have no internet connection on Spotify, try the following steps:

  1. Check your device’s internet connection: Ensure that your device is connected to a working internet connection.
  2. Restart Spotify: Close the Spotify app and reopen it to refresh the connection.
  3. Check your firewall or antivirus settings: Make sure that Spotify is not being blocked by your firewall or antivirus software.
  4. Clear cache and data: Clear the cache and data of the Spotify app and try again.
  5. Reinstall Spotify: Uninstall and reinstall the Spotify app on your device.

Q: Why is Spotify showing “No Internet Connection Detected”?

A: If Spotify is showing “No Internet Connection Detected,” it could be due to issues with your internet connection or firewall settings. Make sure your device is connected to the internet and check your firewall settings to ensure that Spotify is allowed to access the internet.

Q: Can I fix Error Code 4 issue on my own?

A: Yes, you can fix the Spotify Error Code 4 issue on your own by following the troubleshooting steps provided. However, if you are unable to resolve the issue, you may need to seek further assistance from a tech support, like us 🙂

I am a computer engineer holding a bachelor's degree in Computer Science, complemented by a Master's in Business Administration from University of Strathclyde, Scotland. I currently work as a Senior IT Consultant in Melbourne, Australia. With over 15 years of...