Home Assistant Cast fails: "Unable to find a view with path default_view"

I’m trying to cast my dashboard to a Nest Hub, but it doesn’t work. What am I missing?

Here’s what I’m doing:

  1. On my desktop web browser, go to https://cast.home-assistant.io/
  2. Under Home Assistant URL, I enter my ui.nabu.casa URL and hit Authorize
  3. I enter my credentials and hit Log in. All good.
  4. I hit “Start Casting”. In the pop up screen, I select my Nest Hub.
  5. The Nest Hub shows the Nabu casa splash screen and eventually says “Connected”.
  6. On the computer, I can pick a view, there’s only one, called “Home”, which is the intended one.
  7. Nest Hub now shows: “Error: Unable to find a view with path default_view”.

My assumption is that the dashboard I want to cast is missing a variable that’s set to “default_view”, but I can’t figure out where and what exactly is required. Sure enough, in the dashboard’s YAML, I added default_view in multiple places:

views:
  - theme: Backend-selected
    title: Home
    view_path: default_view
    path: default_view
    view: default_view

But it all doesn’t make a difference, the casting error remains the same.

As an additional note, the demo dashboard that the Home Assistant Cast website provides works without issue.

What’s the solution? :blush:

1 Like

I only have “path”, not “view” or “view_path”. Having said that, I stopped using cast.show_lovelace_view and switched to media_player.play_media and set “media_content_id” to the relative url, and “media_content_type” to “lovelace”.

So if your dashboard shows as “https://mydomain.duckdns.org/lovelace-home/default_view” you would set “media_content_id” to “lovelace-home/default_view”.

The reason I switched is because cast.show_lovelace_view seemed to reset after some time, whereas media_player.play_media seems happy to cast for most/all the time.

@richardvinger - I have the same problem with cast.home-assistant.io - demo works fine, I am able to cast and connect to my homeassistant instance and also get “unable to find a view” error message.

I was able to stream a dashboard via Media → selecting the Google NestHub and a dashboard.
However I had to add a statement to configuration.yaml before:

homeassistant:
  external_url: "https://<external_url_of_my_homeassistant>/"
1 Like

I’ve had this problem on numerous Home Assistant installations and have never been able to solve it over a number of years now. Demo cast works just fine, but I get the same unable to find a view with path default_view. So I feel your pain!

Hi,
I’ve been wasting time trying to solve an issue which prevented me from casting from HA to any Google device for few weeks already (Err: Unable to connect to websocket api URL). This comment made me realize what the issue was: I was missing the port in the config. Just wanted to chime in to say thank you ! :grin: