Localization - URL Routing not working correct

Hello everyone, hi Ellen (@Ellen_Larsson )

perhaps there is a different understanding of what the routing function should achieve, or we might be doing something wrong.

Here are our settings briefly:

Bildschirmfoto 2023-12-05 um 09.28.07

We use the dropdown (Locales List) from Webflow for the language switchover


The following issues arise:

1. In the Chrome browser, when I have set 2 languages (English as the primary language, German), the Webflow routing redirects me to the German language. (It functions correctly only in incognito mode.)

Why?

(Apparently, the language headers seem to be processed incorrectly. )

2. If I have set only 2 languages (German as the primary language, English), I land on the correct page. All good so far. However, if I want to view the page in English, it ALWAYS redirects me back to the German page.

Does that make sense?

Thank you already for your help!

Regards

@coolmac Did you use a translation service before on this site? Weglot for example (or another)? If so did you change the A records / Cname back to webflows on the domain-server? Could be it. In your settings I see EN is the only one without a subdirectory. (don’t know if that last part matters)

You also have language settings in Chrome, which can override, as you mention that incognito works… happend to me, when i was working on a corporate site (different cms) same result. So the routing could look at the language settings in the browser.

Hello @Punt, thank you for your message and comments.

Up to now, we haven’t utilized any translation tools, and as a result, we haven’t made any changes to the A records. They still point to Webflow.

Regarding the subdirectory, our aim was to avoid the primary domain from having a subdirectory, for instance: myproject.com/en (where “EN” represents the main language).

The other issue is that point 2 doesn’t seem to work on any browsers (Chrome, Safari, Firefox) when multiple languages are set for the browser, and the site supports those languages.

What is your published site link?

You could replace it pretty easily with your own auto-router if you don’t mind a redirect.

Browsers indicate a series of language codes that they support, with preference scores, like DE 1.0, FR 0.8, ES 0.5. When I build routers, I match that against the site’s available languages to help identify the best match.

Combine that with a cookie, and you can auto-route the user on first visit, and then remember if they’ve change the setting to a different locale.

I’ve not used this feature in Webflow’s Localization but at a glance it looked like this is how they built it, there was a cookie named something like preferred-locale I think. I’m not seeing that now though which suggests either that feature isn’t working, or might be in re-development.

I’d recommend contacting support on this one, they’ll likely have more info.

Hi everyone,

it looks like we’re facing the same issue. We have a site with two languages (English (primary), German), URL routing active, and language buttons. This works for every page except for the index page. The index page is always routed to the user’s preferred language although English is selected.
We would like to avoid having a subdirectory for the primary language as this would require to set up a large number of redirects.

Is there any solution to this?

Thanks!

Same Problem here, primary locale German, secondary locale English. URL Routing enabled.

The Language Switch works everywhere, except if you’re on the homepage “/” and your Browser uses the Websites secondary Locale as the main language. Then you always get redirected back, in this case, to /en. You can’t access home on the primary language.

The URL Routing seems to be broken in general, or at least not working based on locale. If I try to access /ueber-uns (german) I expect to be redirected to /about-us (english) when URL Routing is enabled. But there is nothing happening.

Fastest “fix” is disabling the URL Routing (“Automatic visitor routing”).
i have also written to support, and will let you know when i have an answer.

The Webflow Support answered with a workaround:

I just wanted to let you know that our Engineering team is aware of this behaviour. I don’t have a timeframe for when this will be resolved, but I’ll get back to you here when there’s any update.

In the meantime, a potential workaround for you would be to enable the create subdirectory setting for the primary locale in your Localization settings. This will allow both autorouting and manual switching to work as expected across all pages. Of course, this means that the primary locale will have a subdirectory included in the URL for all pages , and this may not suit you.

Hello, I had the same problem. Yesterday webflow support send me an email saying they fixed the issue. So now the automatic URL rounting should be working fine