By default, Universally rewrites internal links on translated pages to point to the translated version. For example, a link to /about on a French page becomes /fr/about. This ensures visitors stay in their language as they navigate.

Link localization applies to:
- All
<a href>links pointing to pages on the same domain - Canonical URLs (
<link rel="canonical">) - Open Graph URLs (
og:url,og:image,og:video, etc.) - Twitter Card URLs (
twitter:image,twitter:player, etc.)
Use Exclude Link Localization to prevent specific links from being rewritten. This setting is in your project’s Settings tab. Enter one URL pattern per line.
When to Use
Some links should never have a language prefix added:
- File downloads —
/downloads/report.pdfshould not become/fr/downloads/report.pdf - API endpoints —
/api/v1/datamust stay as-is - Admin pages —
/wp-admin/links should not be localized - Static assets —
/wp-content/uploads/image.jpgshould not be prefixed - External service callbacks — payment or auth return URLs
- RSS feeds —
/feed/endpoints
Pattern Syntax
Patterns are matched as URL fragments. If the URL contains the pattern anywhere in its path, the link is excluded from localization.
/wp-content/
/wp-admin/
/api/
/downloads/
/feed/
For example, the pattern /wp-content/ matches any URL containing that string:
/wp-content/uploads/photo.jpg— excluded/wp-content/themes/style.css— excluded/about-wp-content/— also excluded (substring match)
Examples
WordPress sites
/wp-content/
/wp-admin/
/wp-includes/
/wp-login.php
/wp-signup.php
/wp-activate.php
/xmlrpc.php
/wp-cron.php
/wp-json/
/feed/
/comments/feed/
Note: These are configured automatically for WordPress sites. You only need to add custom patterns.
E-commerce
/cart/add
/checkout/
/webhook/
/downloads/
General
/api/
/assets/
/static/
/uploads/
/_next/
How It Works Internally
When Universally processes a translated page, it rewrites URLs in two ways depending on your URL structure:
Subdirectory mode (default)
Links are prefixed with the language code:
/about→/fr/about/blog/post→/fr/blog/post
Subdomain mode
The domain is changed to the language subdomain:
https://example.com/about→https://fr.example.com/about
Excluded patterns bypass this rewriting entirely — the original URL is preserved as-is.
Things to Note
- Patterns are substring matches, not exact matches or wildcards
- External links (different domain) are never localized regardless of this setting
- Links inside elements excluded by CSS selectors are also not localized
- Anchor-only links (
#section) are never localized - The
hreflangattribute on links prevents localization by default (no configuration needed)