2

In a multilingual app, regarding accessibility usages, can we use english for titles, alt etc., or should we adapt accordingly to the language selected?

Example: always use title="Back to the home page" on the logo, even if the selected language is Spanish.

I am pretty sure we need to adapt, but what is the accessibility rule that confirms this?

Thank you.

3
  • 18
    I'm a little confused by this question. Why would it be acceptable to use English for title text when the user has selected a different language? Sep 4, 2023 at 23:20
  • 2
    Nitpick: not english, but English. Sep 5, 2023 at 11:49
  • The idea was to relieve the burden on devs side. Using english as default language for what concern accessibility would have been less work to do (as we are understaffed and that accessibility is not our top priority because of that). To be extra clear, changing language on the page would have changed the language content but not the alt text, aria labels, title (in html code) and so on
    – chamou2099
    Sep 6, 2023 at 11:05

3 Answers 3

8

I'd start with a WCAG's success criterion 3.1.2: Language of Parts which states that:

The human language of each passage or phrase in the content can be programmatically determined except for proper names, technical terms, words of indeterminate language, and words or phrases that have become part of the vernacular of the immediately surrounding text.

So to be accessible in your scenario, you'd have to mark in (HTML) code all the parts of the text with the information of the language of the part, probably with lang attribute.

European standard EN 301 549 V3.2.1: Accessibility requirements for ICT products and services (PDF) removes this requirement from mobile applications.

Then I'd look at Web Accessibility Initiative's (WAI) cognitive accessibility objective on using clear and understandable content. It doesn't straight up mention language but sets the goal for the content of the app.

Lastly I'd use the rule of common sense and put myself in the shoes of non english-speaking blind person. Would your app be accessible to me?

1
  • 7
    I would have put the common sense rule first, rather than last. Accessibility should be first and foremost about helping people, with rules and standards as tools to aid you in that aim, not the beginning and end of your effort. As one page on the W3C site puts it: "Checklists, standards, and laws are important tools to help achieve accessibility — yet sometimes they get the focus instead of the fundamental goal of accessibility: meeting the needs of disabled people in the real world."
    – IMSoP
    Sep 4, 2023 at 17:40
3

Your original question sounds like the user can change the language of the entire page. If that's true, then WCAG 3.1.1 Language of Page is more applicable in that if the user chooses a language for the entire page, then you should specify the lang attribute on the main <html> element (but UX StackExchange is about usability and not programming so I don't want to dive too deep into that).

<html lang="es">

If you also have non-Spanish words on the page, then each of those elements would need their own lang attribute, which is where WCAG 3.1.2 Language of Parts comes into play.

<html lang="es">
<body>
  <p>Hola! Bienvenido a nuestro sitio web.</p>
  ...
  <p lang="en">To contact us...</p>
</body>

(The above is a contrived example and I don't speak Spanish so it could be grammatically incorrect. If the entire page were in Spanish, I wouldn't expect a "contact us" message in English, but it shows how WCAG 3.1.2 Language of Parts is applicable.)

Getting back to your question:

...can we use English for titles, alt etc or should we adapt according to the language selected ?

If the user changes the language of the page, I would expect everything to be translated, including the page title, the title (tooltip) attribute on all elements, the alt text for images, the aria-label for all elements, etc. How would it help a Spanish speaker to leave those elements in English?

As mentioned above, if there are elements that really need to remain in English, they'll need the lang="en" attribute.

2
  • There is one obvious element that should remain in English: "Switch to English version" (if displayed as that kind of text rather than a graphical language selector)
    – Chris H
    Sep 5, 2023 at 8:00
  • Yes, I didn't get into a discussion about the language switcher itself but I did say "if there are elements that really need to remain in English...", so I covered the "obvious" element. Sep 5, 2023 at 13:21
3

I'm a bit surprised why existing answers mention HTML attributes when the question is explicitly about an app... :-)

I don't think we should need to quote any accessibility rules. It's just normal common sense, when you localize an app, you localize the contents visible (in the broadest sense, meaning that the user can come into any kind of contact with it). You do it with every single piece of text that you have, provided this makes sense (eg. an English-Spanish dictionary app will not localize its English content because its purpose is to show two languages). Be it title, UI text, tooltips, semantic labels for screen readers, the works.

Just consider an app switched to Spanish as one to be used by people who don't understand a single word of English—that's the only logical approach.

6
  • "I'm a bit surprised why existing answers mention HTML attributes when the question is explicitely [sic] about an app". Because the OP used title="Back to the home page" as an example, which is HTML. The word app is used generically. Sep 5, 2023 at 13:15
  • "I don't think we should need to quote any accessibility rules.". Did you read the OP? It asked, "what is the accessibility rule that confirm[s] this". Sep 5, 2023 at 13:18
  • @slugolicious I take that as a "frame challenge" - the question says "quote me a rule", and the answer says "we shouldn't need to".
    – IMSoP
    Sep 5, 2023 at 14:39
  • @slugolicious -- Granted, it's not that important that it warrants a long discussion but it doesn't for me. I just read it as "a page in my app has the title 'Back to the home page'". :-) Yes, I read the OP and that's exactly why a replied the way I did: just like we don't normally need to resort to "authoritative rules" when we speak about almost any aspect of programming, I don't think we need to do it here, either. Fortunately for us, programming isn't some kind of a legal challenge... (BTW, thanks for the correction, it was edited from "explicite" and I left it in, I'll go back and fix).
    – Gábor
    Sep 5, 2023 at 15:04
  • ”we don't normally need to resort to "authoritative rules" when we speak about almost any aspect of programming”. First off, we’re not talking about programming. They asked about Accessibility. And secondly, they asked for the rule that applies to Accessibility so that’s how we should answer. Sep 5, 2023 at 18:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.