|\u003Cimg width=\"324\" alt=\"Image\" src=\"https://github.com/user-attachments/assets/cd6f6927-33b3-4b85-a984-64c6cb1f53e5\" />|\n\n#### Proposed Feature: `localeDetector` Option\n\n##### Current Behavior Example\n\nTo illustrate the current behavior, consider the following scenario:\n\n* Accessing `/en/about` and `/ja/about` under the `no_prefix` strategy will not trigger locale detection based on the pathname.\n* As a result, both paths will use the language setting of the build machine during SSG, resulting in both paths potentially being generated in the same language.\n\nScreenshots and repository links demonstrating the current behavior will be provided to further clarify the issue.\n\nTo address this issue, I propose adding a new `localeDetector` option to the module configuration. This option allows specifying the methods for locale detection as follows:\n\n```typescript\ntype LocaleDetector = (\"pathname\" | \"domain\" | \"cookie\" | \"browser\")[];\n\nconst localeDetector: LocaleDetector = [\"pathname\", \"domain\", \"cookie\", \"browser\"];\n```\n\nIf `pathname` is specified, the locale will be automatically detected based on the URL pathname.\n\nThe default value of `localeDetector` will vary depending on the `strategy` value to maintain backward compatibility. For instance, when `no_prefix` is selected, the default value would be:\n\n```javascript\nlocaleDetector: [\"domain\", \"cookie\", \"browser\"]\n```\n\n##### Example Configuration for My Use Case:\n\n```javascript\nstrategy: \"no_prefix\",\nlocaleDetector: [\"pathname\", \"cookie\", \"browser\"]\n```\n\nThis configuration would resolve the issue by enabling locale detection based on pathname while maintaining backward compatibility with existing behavior.\n\nThank you for considering this feature request. I would be happy to provide further clarifications or contribute to the implementation if needed.\n\n\n### Additional information\n\n- [x] Would you be willing to help implement this feature?\n- [ ] Could this feature be implemented as a module?\n\n### Final checks\n\n- [x] Read the [contribution guide](https://nuxt.com/docs/community/contribution) (The contribution guideline of nuxt-modules/i18n is compliant with Nuxt too).\n- [x] Check existing [discussions](https://github.com/nuxt-modules/i18n/discussions) and [issues](https://github.com/nuxt/nuxt/issues).",[3172],{"name":3173,"color":3174},"pending triage","c2e0c6",3609,"nuxt-modules","i18n","open","Add `localeDetector` option to customize locale detection during Vue component rendering","2025-05-16T18:51:35Z","https://github.com/nuxt-modules/i18n/issues/3609",0.59628284,{"description":3184,"labels":3185,"number":3190,"owner":3176,"repository":3177,"state":3178,"title":3191,"updated_at":3192,"url":3193,"score":3194},"### Environment\n\nnpx nuxi info\nWorking directory: C:/Users/senem/MEM22 nuxi 01:42:27\nNuxt project info: (copied to clipboard) nuxi 01:42:27\n\n------------------------------\n- Operating System: Windows_NT\n- Node Version: v20.19.4\n- Nuxt Version: 3.17.7\n- CLI Version: 3.26.2\n- Nitro Version: 2.12.3\n- Package Manager: npm@10.8.2\n- Builder: -\n- User Config: compatibilityDate, devtools, ssr, app, pages, modules, css, postcss, supabase, vite, sourcemap, routeRules, nitro, site, sitemap, plugins, headers, i18n\n- Runtime Modules: @nuxtjs/i18n@10.0.3, @nuxt/eslint@1.6.0, @nuxt/icon@1.15.0, @nuxt/image@1.10.0, @nuxtjs/tailwindcss@6.14.0, @nuxtjs/supabase@1.5.3, @nuxtjs/sitemap@7.4.3\n- Build Modules: -\n------------------------------\n\n👉 Report an issue: https://github.com/nuxt/nuxt/issues/new?template=bug-report.yml\n👉 Suggest an improvement: https://github.com/nuxt/nuxt/discussions/new\n👉 Read documentation: https://nuxt.com\n\n### Reproduction\n\nhttps://github.com/EnsMsgLu/nuxt-i18n-issue\n\n### Describe the bug\n\nit doesnt working with subdomains \n\n\n\n### Additional context\n\n_No response_\n\n### Logs\n\n```shell\n\n```",[3186,3187],{"name":3173,"color":3174},{"name":3188,"color":3189},"need reproduction","CD234A",3767,"Its not working Home page on Subdomain","2025-07-31T10:28:33Z","https://github.com/nuxt-modules/i18n/issues/3767",0.6571024,{"description":3196,"labels":3197,"number":3199,"owner":3176,"repository":3177,"state":3178,"title":3200,"updated_at":3201,"url":3202,"score":3203},"### Environment\n\n- Operating System: `Darwin`\n- Node Version: `v21.7.1`\n- Nuxt Version: `3.16.2`\n- CLI Version: `3.25.0`\n- Nitro Version: `2.11.9`\n- Package Manager: `npm@10.9.0`\n- Builder: `-`\n- User Config: `codegen`, `compatibilityDate`, `css`, `device`, `devtools`, `i18n`, `image`, `modules`, `runtimeConfig`, `scripts`, `srcDir`, `svgo`, `vite`, `watch`\n- Runtime Modules: `@bootstrap-vue-next/nuxt@0.29.3`, `@nuxt/eslint@1.3.0`, `@nuxt/fonts@0.11.2`, `@nuxt/image@1.10.0`, `@nuxt/scripts@0.11.6`, `@nuxtjs/device@3.2.4`, `@nuxtjs/i18n@9.5.3`, `@nuxtjs/stylelint-module@5.2.1`, `nuxt-svgo@4.0.19`, `nuxt-swiper@2.0.0`\n- Build Modules: `-`\n\n\n### Reproduction\n\nHere is the reproduction:\n\nhttps://stackblitz.com/edit/bobbiegoede-nuxt-i18n-starter-rskcxctd\n\n### Describe the bug\n\nWhen you translate your pages with defineI18nRoute (or maybe into `pages` key into i18n config) is getting rid when strategy in no prefixed (bot _no_prefix_ and _prefix_except_default_)\n\n### Additional context\n\n_No response_\n\n### Logs\n\n```shell\n\n```",[3198],{"name":3173,"color":3174},3598,"defineI18nRoute is not working with no_prefix strategy","2025-05-13T14:21:14Z","https://github.com/nuxt-modules/i18n/issues/3598",0.6579355,{"description":3205,"labels":3206,"number":3208,"owner":3176,"repository":3177,"state":3178,"title":3209,"updated_at":3210,"url":3211,"score":3212},"### Environment\n\n```\n- Operating System: Darwin\n- Node Version: v22.18.0\n- Nuxt Version: 4.1.2\n- CLI Version: 3.28.0\n- Nitro Version: 2.12.6\n- Package Manager: npm@10.9.3\n- Builder: -\n- User Config: compatibilityDate, devtools, modules, ssr, i18n\n- Runtime Modules: @nuxtjs/i18n@10.1.0\n- Build Modules: -\n```\n\n### Reproduction\n\nhttps://github.com/invoxiagau/nuxt-18-detectBrowserLanguage\n\n- Run the production `cloud-build` and `cloud-run` scripts (check README), the bug is only occurring when serving static files\n- Set your browser default language as french\n\n### Describe the bug\n\n- Visit `localhost:8080`\n- I18n correctly detects the browser default language and redirects to `/fr`\n- You can see a list of links using different methods to localise links such as `NuxtLinkLocale`, `NuxtLink`+ `localePath`\n- The content is getting translated in french\n- But, the links are not getting updated:\n \nI expect: `/fr/generic-page`\nInstead I get: `/generic-page`\n\nI get the following error in my console:\n```Hydration completed but contains mismatches.```\n\n### Additional context\n\nI'm unable to reproduce this issue with the dev server, only after building and serving the static files using a http web server, in my case nginx.\n\n\n### Logs\n\n```shell\nHydration completed but contains mismatches.\n```",[3207],{"name":3173,"color":3174},3828,"localePath / NuxtLinkLocale hydration mismatches after browserRedirection with http web server","2025-09-29T08:39:16Z","https://github.com/nuxt-modules/i18n/issues/3828",0.66485906,{"description":3214,"labels":3215,"number":3217,"owner":3176,"repository":3177,"state":3178,"title":3218,"updated_at":3219,"url":3220,"score":3221},"### Environment\n\nnuxt: 4.1.2\n@nuxtjs/i18n: 10.1.0\n\n### Reproduction\n\ni can't create minimal reproduction now\n\n### Describe the bug\n\ni need load my locale from backend via api. \nhttps://i18n.nuxtjs.org/docs/guide/lazy-load-translations#basic-usage\nit still work in v9.5.6 but when i upgrade to v10.1.0,i don't see call api to get locale from ssr or csr on production but it still work on dev. I don't know how to fix it.\n\n### Additional context\n\n_No response_\n\n### Logs\n\n```shell\n\n```",[3216],{"name":3173,"color":3174},3823,"@nuxtjs/i18n v10.1.0: i can't load locale from backend, but it still work in v9.5.6","2025-09-17T16:26:49Z","https://github.com/nuxt-modules/i18n/issues/3823",0.6686991,{"description":3223,"labels":3224,"number":3231,"owner":3176,"repository":3177,"state":3232,"title":3233,"updated_at":3234,"url":3235,"score":3236},"### Environment\n\n------------------------------\n- Operating System: Linux\n- Node Version: v20.19.1\n- Nuxt Version: 3.17.5\n- CLI Version: 3.25.1\n- Nitro Version: 2.11.12\n- Package Manager: npm@10.8.2\n- Builder: -\n- User Config: modules, devtools, nitro, i18n\n- Runtime Modules: @nuxtjs/i18n@9.5.5-29143926.54460af\n- Build Modules: -\n------------------------------\n\n### Reproduction\n\nhttps://stackblitz.com/edit/bobbiegoede-nuxt-i18n-starter-b5evupp3?file=nuxt.config.ts\n\n### Describe the bug\n\nWhen the site is generated or pre-rendered in `strategy: 'prefix'`, Browser language detection is not performed but the site always lands on the `defaultLocale` (`ja` in this case).\nThis is a bug present in both `V9` and `V10` and it would be nice to be fixed before the final release.\n\nCurrently the only solution I have found is to specify not to pre-render the `/` page and to start from the others (by the way it is not correct that this page is prerendered in `strategy: 'prefix'`):\n```js \n routeRules: {\n '/': {\n prerender: false,\n },\n '/ja': {\n prerender: true,\n },\n '/it': {\n prerender: true,\n },\n '/en': {\n prerender: true,\n },\n },\n```\n\n### Additional context\n\nI noticed this error when deploying to Netlify, but you can reproduce it with\n`nuxt build`\n`nuxt preview`\n\n### Logs\n\n```shell\n\n```",[3225,3228],{"name":3226,"color":3227},"scope: ssg","85eac7",{"name":3229,"color":3230},"scope: language detection","1B89B8",3678,"closed","Browser language detection on prerendering with `strategy: 'prefix'`","2025-07-29T10:29:39Z","https://github.com/nuxt-modules/i18n/issues/3678",0.63891226,{"description":3238,"labels":3239,"number":3244,"owner":3176,"repository":3177,"state":3232,"title":3245,"updated_at":3246,"url":3247,"score":3248},"### Environment\n\n- Operating System: Windows 11\n- Node Version: 18.18.2\n- Nuxt Version: 3.15.0\n- @nuxtjs/i18n: 9.5.3\n\n### Reproduction\n\nhttps://stackblitz.com/edit/bobbiegoede-nuxt-i18n-starter-7rohnkcc?file=nuxt.config.ts\n\n### Describe the bug\n\nI am using the following configuration:\n\n```\ni18n: {\n locales: [ ... ],\n strategy: 'prefix_except_default',\n langDir: 'lang',\n lazy: true,\n defaultLocale: 'en',\n detectBrowserLanguage: {\n useCookie: true,\n cookieKey: 'i18n_redirected',\n fallbackLocale: 'en',\n redirectOn: 'no prefix',\n alwaysRedirect: true,\n }\n}\n```\n\nExpected:\nA Japanese user is on the link `https://www.xxx.com/ja/about`, now opening the following links should result in the following redirection behavior:\n`https://www.xxx.com/nl/about` → `https://www.xxx.com/nl/about`\n`https://www.xxx.com/about` → `https://www.xxx.com/ja/about`\n`https://www.xxx.com` → `https://www.xxx.com/ja`\n\nThis also matches the documentation:\n`'no prefix' - a more permissive variant of 'root' that will detect the browser locale on the root path ('/') and also on paths that have no locale prefix (like '/foo'). Only effective when using strategy other than 'no_prefix'.`\n\nActual behavior (only listing the problematic case):\n`https://www.xxx.com/nl/about` → `https://www.xxx.com/ja/about`\n\nThe above issue exists in versions v7, v8, and v9.\n\n\n### Additional context\n\n_No response_\n\n### Logs\n\n```shell\n\n```",[3240,3241],{"name":3229,"color":3230},{"name":3242,"color":3243},"possible regression","B78041",3545,"The behavior of redirectOn set to 'no prefix' from version 7 to version 9 is inconsistent with the documentation.","2025-06-22T23:03:38Z","https://github.com/nuxt-modules/i18n/issues/3545",0.6424259,{"description":3250,"labels":3251,"number":3261,"owner":3176,"repository":3177,"state":3232,"title":3262,"updated_at":3263,"url":3264,"score":3265},"### Environment\n\n```\n- Operating System: Darwin\n- Node Version: v22.11.0\n- Nuxt Version: 3.13.2\n- CLI Version: 3.16.0\n- Nitro Version: 2.10.4\n- Package Manager: npm@10.9.0\n- Builder: -\n- User Config: default\n- Runtime Modules: @nuxtjs/i18n@9.1.0, @pinia/nuxt@0.7.0\n- Build Modules: -\n```\n\n### Reproduction\n\nhttps://stackblitz.com/edit/bobbiegoede-nuxt-i18n-starter-l8bdri?file=pages%2Ftest.vue,pages%2Findex.vue but it won't work in stackblitz so it needs to be reproduced in local environment\n\n### Describe the bug\n\nWhen using `\u003CNuxtLinkLocale>` with `to=\"/some-url-in-your-application\"` with `target=\"_blank\"`, locale prefix is not inserted in the resulting URL.\n\n### Additional context\n\nIn my opinion prefix should be added (or omitted if it is a default locale) as I use `\u003CNuxtLinkLocale>` here with exact purpose to direct to my application. Otherwise I would have used just an ordinary `\u003Ca>` tag or even `\u003CNuxtLink>`\n\n### Logs\n\n```shell\n\n```",[3252,3255,3258],{"name":3253,"color":3254},"bug 🐛","ee0701",{"name":3256,"color":3257},"PR Welcome","40922A",{"name":3259,"color":3260},"nuxt-link-locale","B327C3",3252,"NuxtLinkLocale with an attribute target=\"_blank\" does not respect the locale prefix","2025-05-22T15:26:02Z","https://github.com/nuxt-modules/i18n/issues/3252",0.6528722,{"description":3267,"labels":3268,"number":3270,"owner":3176,"repository":3177,"state":3232,"title":3271,"updated_at":3272,"url":3273,"score":3274},"### Environment\n\n------------------------------\n- Operating System: Linux\n- Node Version: v22.14.0\n- Nuxt Version: 3.17.2\n- CLI Version: 3.25.0\n- Nitro Version: 2.11.7\n- Package Manager: pnpm@10.6.5\n- Builder: -\n- User Config: -\n- Runtime Modules: -\n- Build Modules: -\n------------------------------\n\n### Reproduction\n\nI made a fork and modified the playground a bit. Start the playground and go to the `/jatest` page. You will see 404 screen, even though the page exists.\n\nhttps://github.com/MellKam/i18n/tree/v9\n\n### Describe the bug\n\nConsider the following config:\n\n```ts\nexport default defineNuxtConfig({\n modules: ['@nuxtjs/i18n'],\n i18n: {\n strategy: 'prefix_except_default',\n multiDomainLocales: true,\n locales: [\n {\n code: 'en',\n language: 'en-US',\n file: 'en.json',\n name: 'English',\n domains: ['localhost:3000']\n },\n {\n code: 'ja',\n language: 'ja-JP',\n file: 'ja.json',\n name: 'Japanese',\n domains: ['localhost:3000'],\n defaultForDomains: ['localhost:3000']\n }\n ]\n },\n compatibilityDate: '2025-02-04'\n})\n```\n\nThe default locale for domain localhost:3000 would be `ja`. The selected strategy is `prefix_except_default`, so prefix `ja` should be removed from path. \n\nBut let's consider the page path that looks like this: `/jatest`. When we try to go to this page we don't want the prefix to be removed as it's the part of the path and not the prefix of locale. But in `9.5.6` we would actually get 404 with message `Page /test not found`",[3269],{"name":3173,"color":3174},3715,"[v9] Default locale prefix incorrectly removed from route paths that start with locale substring (e.g. /jatest becomes /test)","2025-07-20T20:13:46Z","https://github.com/nuxt-modules/i18n/issues/3715",0.6556081,{"description":3276,"labels":3277,"number":3280,"owner":3176,"repository":3177,"state":3232,"title":3281,"updated_at":3282,"url":3283,"score":3284},"### Environment\n\n- Operating System: Darwin\n- Node Version: v22.17.1\n- Nuxt Version: 4.1.0\n- CLI Version: 3.28.0\n- Nitro Version: 2.12.5\n- Package Manager: pnpm@10.13.1\n- Builder: -\n- User Config: compatibilityDate, devtools, modules, i18n, ssr\n- Runtime Modules: @nuxtjs/i18n@10.0.6\n- Build Modules: -\n\n### Reproduction\n\n`\u003Cremoved link to zip file>`\n\n### Describe the bug\n\n执行 `pnpm generate` \n[intlify] Not found 'welcome' key in 'en' locale messages. \n\n\u003Cimg width=\"835\" height=\"546\" alt=\"Image\" src=\"https://github.com/user-attachments/assets/caf8e9e8-ce41-4789-a6e4-478d2a55c24d\" />\n\n### Additional context\n\n_No response_\n\n### Logs\n\n```shell\n\n```",[3278,3279],{"name":3173,"color":3174},{"name":3188,"color":3189},3807,"静态生成时,.output下 locales语言文件是空的","2025-09-05T01:23:11Z","https://github.com/nuxt-modules/i18n/issues/3807",0.6575813,["Reactive",3286],{},["Set"],["ShallowReactive",3289],{"$fTRc1wZytZ_XrK4EfJfei_Sz-An4H4Yy6syhVxH_PVJc":-1,"$fzhfixdctxLaW26y_d2wUmhCtiGqgzoiHePmLurTh-ic":-1},"/nuxt-modules/i18n/3619"]