# 브라우저 설정에 따라 기본 언어를 설정하는 방법이 있나요?

**URL:** https://meta.discourse.org/t/is-there-a-way-to-set-default-language-based-on-browser-settings/151032
**Category:** Support
**Created:** [5월 11, 2020, 10:48오전 UTC](https://meta.discourse.org/t/is-there-a-way-to-set-default-language-based-on-browser-settings/151032 "2020-05-11T10:48:58Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![hhlp](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/hhlp/32/124988_2.png) [@hhlp](https://meta.discourse.org/u/hhlp)
#### Post date: [5월 11, 2020, 10:48오전 UTC](https://meta.discourse.org/t/is-there-a-way-to-set-default-language-based-on-browser-settings/151032/1 "2020-05-11T10:48:58Z")

</div>

브라우저 설정을 기반으로 등록 사용자와 비등록 사용자 모두에게 기본 언어를 설정할 수 있는 방법이 있을까요?

사이트의 기본 설정이 영어이고, 저는 Firefox나 Chrome을 스페인어로 사용 중인데…

> [@Is there any way to let language selector display 'English' instead of 'en'?](https://meta.discourse.org/t/is-there-any-way-to-let-language-selector-display-english-instead-of-en/14518/6):
>
> This is now complete in the admin section. Per: If admins enables user locales then we don’t get it cry However user locale selection is kind of rare, #pr-welcome to make the user selector consistent with admin.

> [@Changing language for non registered user](https://meta.discourse.org/t/changing-language-for-non-registered-user/113240):
>
> Hi, Some of our customers want to be able to visit our discourse in their language (we are in Switzerland, we have to play with french, german, italian and english). Thse customers are not / don’t want to register. How could we add a way for them to change language of Discourse? I could see a dropdown menu listing some languages in the header. Is there already a plugin, of some code I could use ? Thanks

이것이 가능한가요?

감사합니다.

---

<div class="post-metadata">

### Author: ![osioke](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/osioke/32/238946_2.png) [@osioke](https://meta.discourse.org/u/osioke)
#### Post date: [5월 11, 2020, 3:39오후 UTC](https://meta.discourse.org/t/is-there-a-way-to-set-default-language-based-on-browser-settings/151032/2 "2020-05-11T15:39:05Z")

</div>

Discourse는 `set locale from accept language header` 사이트 설정이 활성화된 경우 브라우저의 로케일을 사용하여 사용자의 로케일을 설정합니다. 익명 사용자(및 사이트에 가입하는 신규 사용자)의 경우, 브라우저의 언어 헤더를 기반으로 로케일이 설정됩니다.

이 기능은 `login required` 사이트 설정이 활성화된 경우에만 올바르게 작동합니다. `login required` 설정이 활성화되지 않은 사이트에서는 `set locale from accept language header` 설정이 로그인하지 않은 사용자에게 사이트가 잘못된 로케일로 표시되도록 할 수 있습니다. 이 문제가 발생하는 이유는 사이트의 로딩 시간을 단축하기 위해 로그인하지 않은 사용자에게 표시되는 콘텐츠를 캐싱하기 때문입니다.

모든 사용자는 사용자 설정에서 언어를 변경할 수 있습니다.

---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [6월 10, 2020, 3:44오후 UTC](https://meta.discourse.org/t/is-there-a-way-to-set-default-language-based-on-browser-settings/151032/3 "2020-06-10T15:44:36Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.

---

<div class="post-metadata">

### Author: ![riking](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/riking/32/170938_2.png) [@riking](https://meta.discourse.org/u/riking)
#### Post date: [7월 23, 2020, 12:31오전 UTC](https://meta.discourse.org/t/is-there-a-way-to-set-default-language-based-on-browser-settings/151032/4 "2020-07-23T00:31:27Z")

</div>

`set locale from accept language header`의 문제가 해결되어 더 이상 "실험적"이 아닙니다.

> <https://github.com/discourse/discourse/pull/10289>
>
> This only applies when allow\_user\_locale is enabled
