alexa_media_player: Connection Error! (Errno -2) Name does not resolve

I wanted to reinstall Alexa Media Player because I was having problems. Unfortunately it won’t install anymore, I always get the error below. I have not changed anything on my system. Can anyone help?


System details

  • Home-assistant (version): 2023.04.1
  • alexa_media (version from or HA startup): 4.6.2
  • Amazon 2FA is enabled (y/n).: yes

About this issue

  • Original URL
  • State: closed
  • Created a year ago
  • Comments: 15 (2 by maintainers)

Most upvoted comments

Same Problem over here since today… out of nowhere. Everything was workong well since a few hours ago.

Connection Error! Please try refreshing. If this persists, please report this error to here: [Errno -2] Name does not resolve

Didn’t update anything

EDIT: this solved it:

I had some difficulty adding the Alexa integration (v4.3.2) in HA 2022.11.05. I followed the steps and got as far as entering the one time code and being taken to the Alexa website sign-in screen. But when tried to log in I got an error: cannot connect to host name … does not resolve home assistant.

Here is what worked for me.

In HA, open Terminal (add-on)

From command line enter this command: ha dns options --servers dns://

Then enter this command: ha dns restart

After doing this, I tried again to integrate Alexa Media Player and was able to make it all the way. Hope this helps someone.

credits to

not a clean solution at all but i’ll be able to see what breaks now. Maybe the author can adjust this in the next release.