[{"data":1,"prerenderedAt":837},["ShallowReactive",2],{"guide-slug-generation-multilingual-urls":3},{"id":4,"title":5,"body":6,"date":829,"description":830,"extension":831,"meta":832,"navigation":258,"path":833,"readingTime":329,"seo":834,"stem":835,"__hash__":836},"guides\u002Fguides\u002Fslug-generation-multilingual-urls.md","Slug Generation for Multilingual URLs: Best Practices",{"type":7,"value":8,"toc":810},"minimark",[9,14,18,21,25,30,33,96,107,111,114,167,179,183,186,454,457,461,465,468,561,564,568,571,609,612,616,619,625,629,640,644,680,684,687,740,744,769,773,794,798,806],[10,11,13],"h2",{"id":12},"why-multilingual-slugs-are-hard","Why Multilingual Slugs Are Hard",[15,16,17],"p",{},"English URL slugs are straightforward: lowercase, replace spaces with hyphens, strip special characters. But multilingual content introduces characters that don't fit ASCII — accented letters (é, ü, ñ), non-Latin scripts (中文, عربي, キリル), and ligatures (æ, ß).",[15,19,20],{},"Now RFC 3986 restricts URLs to a limited ASCII subset. Internationalized Resource Identifiers (IRIs) extend this, but in practice browsers and servers rely on Punycode encoding for non-ASCII domain names and percent-encoding for path segments. Your slug generation strategy must respect these constraints while remaining readable and SEO-friendly.",[10,22,24],{"id":23},"three-strategies-for-multilingual-slugs","Three Strategies for Multilingual Slugs",[26,27,29],"h3",{"id":28},"strategy-1-transliterate-to-ascii","Strategy 1: Transliterate to ASCII",[15,31,32],{},"Convert non-ASCII characters to their closest ASCII equivalent:",[34,35,36,52],"table",{},[37,38,39],"thead",{},[40,41,42,46,49],"tr",{},[43,44,45],"th",{},"Original",[43,47,48],{},"Transliterated",[43,50,51],{},"Slug",[53,54,55,70,83],"tbody",{},[40,56,57,61,64],{},[58,59,60],"td",{},"Café au lait",[58,62,63],{},"Cafe au lait",[58,65,66],{},[67,68,69],"code",{},"cafe-au-lait",[40,71,72,75,78],{},[58,73,74],{},"München",[58,76,77],{},"Munchen",[58,79,80],{},[67,81,82],{},"munchen",[40,84,85,88,91],{},[58,86,87],{},"Szczęść Boże",[58,89,90],{},"Szczesc Boze",[58,92,93],{},[67,94,95],{},"szczesc-boze",[15,97,98,102,103,106],{},[99,100,101],"strong",{},"Pros",": Fully ASCII-safe, no encoding issues, works everywhere\n",[99,104,105],{},"Cons",": Loss of meaning for non-Latin scripts (\"北京\" → \"bei jing\" loses the visual connection), inconsistent transliteration libraries",[26,108,110],{"id":109},"strategy-2-preserve-unicode-recommended-for-non-latin","Strategy 2: Preserve Unicode (Recommended for non-Latin)",[15,112,113],{},"Keep the original characters in the slug. The browser percent-encodes them automatically:",[34,115,116,128],{},[37,117,118],{},[40,119,120,123,126],{},[43,121,122],{},"Language",[43,124,125],{},"Title",[43,127,51],{},[53,129,130,142,155],{},[40,131,132,135,138],{},[58,133,134],{},"Chinese",[58,136,137],{},"北京旅游指南",[58,139,140],{},[67,141,137],{},[40,143,144,147,150],{},[58,145,146],{},"Arabic",[58,148,149],{},"دليل السفر",[58,151,152],{},[67,153,154],{},"دليل-السفر",[40,156,157,160,163],{},[58,158,159],{},"Japanese",[58,161,162],{},"東京観光ガイド",[58,164,165],{},[67,166,162],{},[15,168,169,171,172,174,175,178],{},[99,170,101],{},": Preserves meaning, better click-through rates for native readers\n",[99,173,105],{},": URLs look encoded when copied (",[67,176,177],{},"%E5%8C%97%E4%BA%AC","), some analytics tools don't handle percent-encoded URLs well",[26,180,182],{"id":181},"strategy-3-hybrid-approach","Strategy 3: Hybrid Approach",[15,184,185],{},"Use ASCII slugs for Latin-script languages and Unicode slugs for non-Latin:",[187,188,193],"pre",{"className":189,"code":190,"language":191,"meta":192,"style":192},"language-javascript shiki shiki-themes github-light github-dark","function generateSlug(text, locale) {\n  const normalized = text.toLowerCase().trim()\n\n  if (isLatinScript(locale)) {\n    return transliterate(normalized)\n      .replace(\u002F[^a-z0-9]+\u002Fg, '-')\n      .replace(\u002F^-|-$\u002Fg, '')\n  }\n\n  return normalized\n    .replace(\u002F\\s+\u002Fg, '-')\n    .replace(\u002F[^\\p{L}\\p{N}-]\u002Fgu, '')\n}\n","javascript","",[67,194,195,225,253,260,275,287,327,363,369,374,383,410,448],{"__ignoreMap":192},[196,197,200,204,208,212,216,219,222],"span",{"class":198,"line":199},"line",1,[196,201,203],{"class":202},"szBVR","function",[196,205,207],{"class":206},"sScJk"," generateSlug",[196,209,211],{"class":210},"sVt8B","(",[196,213,215],{"class":214},"s4XuR","text",[196,217,218],{"class":210},", ",[196,220,221],{"class":214},"locale",[196,223,224],{"class":210},") {\n",[196,226,228,231,235,238,241,244,247,250],{"class":198,"line":227},2,[196,229,230],{"class":202},"  const",[196,232,234],{"class":233},"sj4cs"," normalized",[196,236,237],{"class":202}," =",[196,239,240],{"class":210}," text.",[196,242,243],{"class":206},"toLowerCase",[196,245,246],{"class":210},"().",[196,248,249],{"class":206},"trim",[196,251,252],{"class":210},"()\n",[196,254,256],{"class":198,"line":255},3,[196,257,259],{"emptyLinePlaceholder":258},true,"\n",[196,261,263,266,269,272],{"class":198,"line":262},4,[196,264,265],{"class":202},"  if",[196,267,268],{"class":210}," (",[196,270,271],{"class":206},"isLatinScript",[196,273,274],{"class":210},"(locale)) {\n",[196,276,278,281,284],{"class":198,"line":277},5,[196,279,280],{"class":202},"    return",[196,282,283],{"class":206}," transliterate",[196,285,286],{"class":210},"(normalized)\n",[196,288,290,293,296,298,302,305,308,311,314,316,319,321,324],{"class":198,"line":289},6,[196,291,292],{"class":210},"      .",[196,294,295],{"class":206},"replace",[196,297,211],{"class":210},[196,299,301],{"class":300},"sZZnC","\u002F",[196,303,304],{"class":233},"[",[196,306,307],{"class":202},"^",[196,309,310],{"class":233},"a-z0-9]",[196,312,313],{"class":202},"+",[196,315,301],{"class":300},[196,317,318],{"class":202},"g",[196,320,218],{"class":210},[196,322,323],{"class":300},"'-'",[196,325,326],{"class":210},")\n",[196,328,330,332,334,336,338,340,344,347,349,352,354,356,358,361],{"class":198,"line":329},7,[196,331,292],{"class":210},[196,333,295],{"class":206},[196,335,211],{"class":210},[196,337,301],{"class":300},[196,339,307],{"class":202},[196,341,343],{"class":342},"sA_wV","-",[196,345,346],{"class":202},"|",[196,348,343],{"class":342},[196,350,351],{"class":202},"$",[196,353,301],{"class":300},[196,355,318],{"class":202},[196,357,218],{"class":210},[196,359,360],{"class":300},"''",[196,362,326],{"class":210},[196,364,366],{"class":198,"line":365},8,[196,367,368],{"class":210},"  }\n",[196,370,372],{"class":198,"line":371},9,[196,373,259],{"emptyLinePlaceholder":258},[196,375,377,380],{"class":198,"line":376},10,[196,378,379],{"class":202},"  return",[196,381,382],{"class":210}," normalized\n",[196,384,386,389,391,393,395,398,400,402,404,406,408],{"class":198,"line":385},11,[196,387,388],{"class":210},"    .",[196,390,295],{"class":206},[196,392,211],{"class":210},[196,394,301],{"class":300},[196,396,397],{"class":233},"\\s",[196,399,313],{"class":202},[196,401,301],{"class":300},[196,403,318],{"class":202},[196,405,218],{"class":210},[196,407,323],{"class":300},[196,409,326],{"class":210},[196,411,413,415,417,419,421,423,425,429,432,434,437,439,442,444,446],{"class":198,"line":412},12,[196,414,388],{"class":210},[196,416,295],{"class":206},[196,418,211],{"class":210},[196,420,301],{"class":300},[196,422,304],{"class":233},[196,424,307],{"class":202},[196,426,428],{"class":427},"snhLl","\\p",[196,430,431],{"class":233},"{L}",[196,433,428],{"class":427},[196,435,436],{"class":233},"{N}-]",[196,438,301],{"class":300},[196,440,441],{"class":202},"gu",[196,443,218],{"class":210},[196,445,360],{"class":300},[196,447,326],{"class":210},[196,449,451],{"class":198,"line":450},13,[196,452,453],{"class":210},"}\n",[15,455,456],{},"This gives Latin-script users clean ASCII URLs while preserving readability for CJK and other scripts.",[10,458,460],{"id":459},"handling-specific-scripts","Handling Specific Scripts",[26,462,464],{"id":463},"accented-latin-characters","Accented Latin Characters",[15,466,467],{},"Use Unicode Normalization Form D (NFD) to decompose accented characters, then strip combining marks:",[187,469,471],{"className":189,"code":470,"language":191,"meta":192,"style":192},"function removeAccents(text) {\n  return text.normalize('NFD').replace(\u002F[\\u0300-\\u036f]\u002Fg, '')\n}\n\nremoveAccents('café')  \u002F\u002F 'cafe'\nremoveAccents('Zürich')  \u002F\u002F 'Zurich'\n",[67,472,473,486,522,526,530,547],{"__ignoreMap":192},[196,474,475,477,480,482,484],{"class":198,"line":199},[196,476,203],{"class":202},[196,478,479],{"class":206}," removeAccents",[196,481,211],{"class":210},[196,483,215],{"class":214},[196,485,224],{"class":210},[196,487,488,490,492,495,497,500,503,505,507,509,512,514,516,518,520],{"class":198,"line":227},[196,489,379],{"class":202},[196,491,240],{"class":210},[196,493,494],{"class":206},"normalize",[196,496,211],{"class":210},[196,498,499],{"class":300},"'NFD'",[196,501,502],{"class":210},").",[196,504,295],{"class":206},[196,506,211],{"class":210},[196,508,301],{"class":300},[196,510,511],{"class":233},"[\\u0300-\\u036f]",[196,513,301],{"class":300},[196,515,318],{"class":202},[196,517,218],{"class":210},[196,519,360],{"class":300},[196,521,326],{"class":210},[196,523,524],{"class":198,"line":255},[196,525,453],{"class":210},[196,527,528],{"class":198,"line":262},[196,529,259],{"emptyLinePlaceholder":258},[196,531,532,535,537,540,543],{"class":198,"line":277},[196,533,534],{"class":206},"removeAccents",[196,536,211],{"class":210},[196,538,539],{"class":300},"'café'",[196,541,542],{"class":210},")  ",[196,544,546],{"class":545},"sJ8bj","\u002F\u002F 'cafe'\n",[196,548,549,551,553,556,558],{"class":198,"line":289},[196,550,534],{"class":206},[196,552,211],{"class":210},[196,554,555],{"class":300},"'Zürich'",[196,557,542],{"class":210},[196,559,560],{"class":545},"\u002F\u002F 'Zurich'\n",[15,562,563],{},"This handles French, German, Spanish, Portuguese, and most European languages.",[26,565,567],{"id":566},"cjk-characters","CJK Characters",[15,569,570],{},"Chinese, Japanese, and Korean characters don't decompose via NFD. Decide per-language:",[572,573,574,584,596],"ul",{},[575,576,577,579,580,583],"li",{},[99,578,134],{},": Preserve Unicode for readability (",[67,581,582],{},"北京旅游",")",[575,585,586,588,589,592,593,583],{},[99,587,159],{},": Some sites use romaji (",[67,590,591],{},"tokyo-kanko","), others preserve kana\u002Fkanji (",[67,594,595],{},"東京観光",[575,597,598,601,602,605,606,583],{},[99,599,600],{},"Korean",": Hangul can be preserved (",[67,603,604],{},"서울-여행",") or transliterated (",[67,607,608],{},"seoul-yeohaeng",[15,610,611],{},"Google has stated that CJK URLs work fine for indexing. Preserve the script when your audience reads it natively.",[26,613,615],{"id":614},"arabic-and-hebrew-rtl","Arabic and Hebrew (RTL)",[15,617,618],{},"Right-to-left scripts in URLs can cause display confusion. Browsers handle the encoding, but the visual representation in the address bar may look odd. Test in multiple browsers.",[15,620,621,624],{},[99,622,623],{},"Recommendation",": Transliterate Arabic and Hebrew to ASCII unless your audience strongly prefers native script URLs.",[26,626,628],{"id":627},"cyrillic","Cyrillic",[15,630,631,632,635,636,639],{},"Russian site owners commonly transliterate to ASCII (",[67,633,634],{},"московский-путеводитель"," → ",[67,637,638],{},"moskovskiy-putevoditel","). This avoids visual ambiguity with Latin characters (Cyrillic \"а\" looks identical to Latin \"a\") which can enable homograph phishing.",[10,641,643],{"id":642},"seo-considerations","SEO Considerations",[572,645,646,652,662,668,674],{},[575,647,648,651],{},[99,649,650],{},"Google handles both ASCII and Unicode slugs"," — no ranking penalty for either approach",[575,653,654,661],{},[99,655,656,657,660],{},"Use ",[67,658,659],{},"hreflang"," tags"," to associate translated URLs with their language",[575,663,664,667],{},[99,665,666],{},"Keep slugs consistent"," — the same content should always generate the same slug",[575,669,670,673],{},[99,671,672],{},"Avoid mixing scripts"," in a single slug — don't combine Latin and CJK characters in one URL segment",[575,675,676,679],{},[99,677,678],{},"Shorter slugs perform better"," — transliteration produces shorter URLs than percent-encoded Unicode",[10,681,683],{"id":682},"normalization-pipeline","Normalization Pipeline",[15,685,686],{},"A robust slug generator follows these steps:",[688,689,690,696,702,708,714,720,729,735],"ol",{},[575,691,692,695],{},[99,693,694],{},"Trim"," leading and trailing whitespace",[575,697,698,701],{},[99,699,700],{},"Normalize"," to NFC (composed form) for consistent representation",[575,703,704,707],{},[99,705,706],{},"Locale-specific processing"," — transliterate or preserve based on script",[575,709,710,713],{},[99,711,712],{},"Lowercase"," for Latin scripts (skip for CJK where case doesn't apply)",[575,715,716,719],{},[99,717,718],{},"Replace separators"," — spaces and underscores to hyphens",[575,721,722,725,726,583],{},[99,723,724],{},"Strip remaining"," non-word characters (regex: ",[67,727,728],{},"[^\\p{L}\\p{N}-]",[575,730,731,734],{},[99,732,733],{},"Collapse"," multiple hyphens into one",[575,736,737,739],{},[99,738,694],{}," leading and trailing hyphens",[10,741,743],{"id":742},"key-takeaways","Key Takeaways",[572,745,746,749,752,755,758,763,766],{},[575,747,748],{},"Multilingual slugs require choosing between transliteration, Unicode preservation, or a hybrid approach",[575,750,751],{},"Transliterate Latin-script accents using NFD normalization and combining mark removal",[575,753,754],{},"Preserve CJK characters for native audiences — Google indexes them correctly",[575,756,757],{},"Transliterate Arabic and Hebrew to avoid RTL display issues",[575,759,656,760,762],{},[67,761,659],{}," tags to link translated pages across languages",[575,764,765],{},"Follow a consistent normalization pipeline to generate stable, repeatable slugs",[575,767,768],{},"Avoid mixing scripts in a single slug segment",[10,770,772],{"id":771},"related-guides","Related Guides",[572,774,775,782,788],{},[575,776,777],{},[778,779,781],"a",{"href":780},"\u002Fguides\u002Furl-slug-guide","URL Slug Guide",[575,783,784],{},[778,785,787],{"href":786},"\u002Fguides\u002Fseo-friendly-urls","SEO-Friendly URLs",[575,789,790],{},[778,791,793],{"href":792},"\u002Fguides\u002Fslugification-how-it-works","Slugification: How It Works",[10,795,797],{"id":796},"try-it-yourself","Try It Yourself",[15,799,800,801,805],{},"Generate URL slugs for any language instantly with our free ",[778,802,804],{"href":803},"\u002Ftools\u002Fslug-generator","Slug Generator",". Paste your title, choose a strategy, and get a clean, SEO-friendly slug in one click.",[807,808,809],"style",{},"html pre.shiki code .szBVR, html code.shiki .szBVR{--shiki-default:#D73A49;--shiki-dark:#F97583}html pre.shiki code .sScJk, html code.shiki .sScJk{--shiki-default:#6F42C1;--shiki-dark:#B392F0}html pre.shiki code .sVt8B, html code.shiki .sVt8B{--shiki-default:#24292E;--shiki-dark:#E1E4E8}html pre.shiki code .s4XuR, html code.shiki .s4XuR{--shiki-default:#E36209;--shiki-dark:#FFAB70}html pre.shiki code .sj4cs, html code.shiki .sj4cs{--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .sZZnC, html code.shiki .sZZnC{--shiki-default:#032F62;--shiki-dark:#9ECBFF}html pre.shiki code .sA_wV, html code.shiki .sA_wV{--shiki-default:#032F62;--shiki-dark:#DBEDFF}html pre.shiki code .snhLl, html code.shiki .snhLl{--shiki-default:#22863A;--shiki-default-font-weight:bold;--shiki-dark:#85E89D;--shiki-dark-font-weight:bold}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .sJ8bj, html code.shiki .sJ8bj{--shiki-default:#6A737D;--shiki-dark:#6A737D}",{"title":192,"searchDepth":227,"depth":227,"links":811},[812,813,818,824,825,826,827,828],{"id":12,"depth":227,"text":13},{"id":23,"depth":227,"text":24,"children":814},[815,816,817],{"id":28,"depth":255,"text":29},{"id":109,"depth":255,"text":110},{"id":181,"depth":255,"text":182},{"id":459,"depth":227,"text":460,"children":819},[820,821,822,823],{"id":463,"depth":255,"text":464},{"id":566,"depth":255,"text":567},{"id":614,"depth":255,"text":615},{"id":627,"depth":255,"text":628},{"id":642,"depth":227,"text":643},{"id":682,"depth":227,"text":683},{"id":742,"depth":227,"text":743},{"id":771,"depth":227,"text":772},{"id":796,"depth":227,"text":797},"2026-05-28","Learn how to generate URL slugs for multilingual content — handling accented characters, CJK, Arabic script, and SEO implications across languages.","md",{"immutable":258},"\u002Fguides\u002Fslug-generation-multilingual-urls",{"title":5,"description":830},"guides\u002Fslug-generation-multilingual-urls","0cL3ePaQKL5OwVBdoCrqWLiGHrOgdbU326iCyGULNuM",1780401336798]