Issue with Stripe API When Using Hebrew as Primary Language in Bubble App

I’m encountering an issue with my Bubble app integrated with Stripe’s API. Here’s the situation:
Stripe error: Invalid locale: must be one of auto, bg, cs, da, de, el, en, en-GB, es, es-419, et, fi, fil, fr, fr-CA, hr, hu, id, it, ja, ko, lt, lv, ms, mt, nb, nl, pl, pt, pt-BR, ro, ru, sk, sl, sv, th, tr, vi, zh, zh-HK, or zh-TW

When I set the app’s primary language to English everything works perfectly with Stripe’s API.
However, when I switch the primary language to Hebrew (which I need for right-to-left support), the integration stops working, and I get a Stripe error saying:

This seems to be related to language settings in Bubble. Hebrew enables the necessary right-to-left formatting, but it appears to conflict with Stripe’s functionality.

Could you please help me resolve this? My goal is to keep using Hebrew as the app’s primary language while maintaining full Stripe API functionality.

If this is a limitation, is there any workaround you can suggest, such as enabling RTL styling without changing the app’s primary language?
Thank you in advance for your help.

Best regards,
Nir

Hi @nirlondonbusiness,

The issue is Stripe does not support Hebrew (he_li) while Bubble does. You’ll have to force one of the supported languages using the URL parameter locale=xx

Hope that helps!

1 Like

As @esardila noted, you can override the locale that Stripe detects from the user’s browser. ICYMI, in order to do so you’ll need to configure your own Stripe API calls using Bubble’s API Connector plugin instead of using Bubble’s Stripe plugin.

1 Like

So on every page do I need to add to the url parameter “eng_us”?

Hey @nirlondonbusiness,

When using the Stripe API, as @davidb suggested, you can pass the “locale” parameter when creating the checkout session link. Here the documentation

This topic was automatically closed after 70 days. New replies are no longer allowed.