Google TTS base_url not always needed

I just got it to work on my system by removing base_url: from the configuration.yaml file. I had problems getting TTS to work for the longest time and I never thought of that being a possible cause until today. I don’t know if I ever tried TTS in the past without base_url: in the configuration. I most likely entered all of that info in thinking I needed to make sure it was there before ever testing TTS.

Just putting that out there in case someone else can’t get TTS to work and they think they have to have base_url: like I thought I did.

So a good idea might be to first try TTS without base_url: in the configuration by turning on Advanced Mode in profile then going to the services page in Developer Tools.

the base_url: option for TTS is an override and optional. by default, the TTS component will use the internal URL set for your HA install if you don’t use base_url:.

what your statement tells me is you possibly had an incorrect value set in your base_url: option. which is why it didn’t work until you removed the option.

1 Like

What matters is that even when the instructions make it seem like base_url: is needed trying the configuration without base_url: might work for some like it did for me. I’m interested in getting things to work and not so much understanding why it did work one way and not the other.

I think the main point is, that if you use a Google-Cast device for tts you must not use a hostname in the internal URL or in base_url:, it has to be the ip-number, as no name resolution is performed.

Why would I include something if it is easier to exclude it? So, no reason to include base_url: if excluding it works. That way I don’t have to worry if it should have an IP instead of a hostname.

You are totally right, but that was not my point.

Many people, me included, used a hostname in the internal URL. In this case TTS won’t work. So as a workaround, they defined the base_url with an ip. This way TTS works again.

If you define your internal URL with an ip in the first place, there is no need for an override with base_url.

The fact that base_url: is needed in some cases doesn’t make and it incorrect that base_url: isn’t always needed. So examples of when base_url: is needed is a side subject. I guess that is fine since I see threads going into different related subjects a lot even if they don’t disprove the original statement. I just dion’t see the need to go OT.