Our website is available in six different languages. Users have a profile that they can fill with text-based information.

This leads to the following issue: The information given by the user will be in one specific language that will not match at least 5 languages the site supports. But, of course, the profile can be accessed in all languages the site offers. Then all menu items etc. will show in the desired language, but the main content will stay in the language of the creator.

We are using hreflang, of course, which works fine for the content we create ourselves in six languages. But it will fail, of course, with all the ugc content of the profile pages that is only available in the mother tongue of the profile's owner.

How should a webmaster deal with this regarding SEO?

1 Answer 1


Using hreflang is a fine practice, but you should also specify lang on the <html> tag of the linked resource (assuming it's an HTML page). Furthermore, lang can be specified on any element, so if you know the language of some content differs from that of its parent, you should specify lang on the HTML element that encloses that content, e.g. use <div lang="fr-FR"> for the UGC block whilst using <html lang="en-US"> for the page itself. If the language of the content is unknown, you can use an empty lang value, e.g. <div lang="">.

Reference: WHATWG HTML living spec, § "The lang and xml:lang attributes".

  • Google has said they ignore the lang attribute. All you said was a good idea but it won't affect SEO. Commented Jan 9, 2021 at 1:12

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.