Overview
ShahiTranslate Pro offers four URL structure options for multilingual sites. The URL structure affects SEO, user experience, and technical implementation. Choose the right structure for your site’s goals and constraints.
URL Structure Comparison
| Structure | Example | SEO | Setup | Multi-Domain | Recommended |
|———–|———|—–|——-|————–|————-|
| Sub-directory | site.com/es/page/ | ⭐⭐⭐⭐⭐ | Easy | No | ✅ Yes |
| Sub-domain | es.site.com/page/ | ⭐⭐⭐⭐ | Medium | Optional | For large sites |
| Query Parameter | site.com/page/?lang=es | ⭐⭐ | Very easy | No | Quick testing only |
| Custom Domain | sitio.es/page/ | ⭐⭐⭐⭐⭐ | Complex | Required | Enterprise only |
Sub-directory Structure (Recommended)
How It Works
URL Format:
`
English (default): https://example.com/about/
Spanish: https://example.com/es/about/
French: https://example.com/fr/about/
German: https://example.com/de/about/
`
Blog Posts:
`
English: https://example.com/blog/my-article/
Spanish: https://example.com/es/blog/my-article/
French: https://example.com/fr/blog/my-article/
`
WooCommerce:
`
English: https://example.com/product/leather-wallet/
Spanish: https://example.com/es/producto/billetera-de-cuero/
`
Configuration
Enable Sub-directory Structure:
`
Settings → SEO & URLs
URL Structure: [Sub-directory (/es/) ▼]
Language Path Prefix:
☑ Add language code before URL
Format: /{language_code}/{slug}
Examples:
/es/about/
/fr/contact/
/de/produkte/
Save Changes
`
Benefits
SEO Advantages:
- ✅ Best for SEO (Google confirmed)
- ✅ All languages on same domain
- ✅ Domain authority shared across languages
- ✅ Easy hreflang implementation
- ✅ Single sitemap for all languages
- ✅ Google Search Console single property
- ✅ Simple to implement
- ✅ Works with any hosting
- ✅ No SSL certificate complications
- ✅ Easy to maintain
- ✅ Clear language separation
- ✅ Clear which language is active
- ✅ Easy to switch languages (just change /es/ to /fr/)
- ✅ Bookmarkable language-specific URLs
- ✅ Sharable links preserve language
- Multi-region sites (en-US, en-GB, en-AU)
- Equal weight to all languages
- Explicit language indication desired
- es.example.com → Spanish
- fr.example.com → French
- de.example.com → German
- ✅ Good SEO (Google treats as related sites)
- ✅ Language-specific targeting
- ✅ Each language can have separate hosting
- ✅ Can have different content per language
- ✅ Language isolation
- ✅ Separate analytics properties
- ✅ Different server configs per language
- ✅ Flexible infrastructure
- ✅ Each language can scale independently
- ✅ Can use different CDNs per language
- ✅ Regional server optimization
- ❌ More complex setup
- ❌ Requires DNS configuration
- ❌ Multiple SSL certificates needed (or wildcard SSL)
- ❌ Google Search Console multiple properties
- ❌ Domain authority split across sub-domains
- ❌ Backlinks don’t consolidate
- ❌ Each sub-domain builds authority separately
- ❌ More complex analytics setup
- ❌ Cookie sharing challenges
- ❌ More server configuration
- ✅ Easiest to implement
- ✅ No server configuration needed
- ✅ Works instantly
- ✅ No DNS changes required
- ✅ No rewrite rules needed
- ✅ Works with all hosting
- ✅ No SSL complications
- ✅ Compatible with all plugins
- ✅ Testing friendly
- ❌ Worst for SEO
- ❌ Google may ignore URL parameters
- ❌ Duplicate content risk
- ❌ Harder to crawl/index
- ❌ Not URL-friendly
- ❌ Longer URLs
- ❌ Less memorable
- ❌ Parameter can get lost
- ❌ Not bookmarked correctly sometimes
- ❌ May conflict with other parameters
- ❌ Analytics complications
- ❌ Social sharing issues
- 🧪 Testing translation setup
- 🚀 Quick prototype
- 🛠️ Development environment
- 📊 A/B testing translations
- ❌ Production sites
- ❌ SEO-focused sites
- ❌ Professional websites
- ❌ E-commerce
- Enable Multisite:
- Install Network:
- Configure Network:
- Map Domains:
- Domain Mapping Plugin:
- example.com
- ejemplo.es
- exemple.fr
- beispiel.de
- ⭐ Best for local SEO
- ⭐ Country-specific domains (.es, .fr, .de)
- ⭐ Local search ranking boost
- ⭐ Trust signals for local users
- ⭐ Each domain ranks independently
- ✅ Localized brand names
- ✅ Regional trust
- ✅ Local market positioning
- ❌ Most complex setup
- ❌ Requires Multisite
- ❌ Multiple domain registrations
- ❌ Multiple SSL certificates
- ❌ Complex maintenance
- ❌ Domain registration fees (×4-10)
- ❌ SSL certificates (or wildcard)
- ❌ Potential separate hosting
- ❌ Higher maintenance costs
- ❌ Separate analytics properties
- ❌ Cookie/session complications
- ❌ Content sync challenges
- ❌ More complex deployment
- ❌ No domain authority sharing
- ❌ Backlinks don’t consolidate
- ❌ Must build authority per domain
- ❌ More complex hreflang setup
- 🏢 Large enterprises
- 🌍 Distinct regional brands
- 💰 High-budget projects
- 📈 Mature markets with local presence
- 🎯 Country-specific strategies
- ❌ Small-medium businesses
- ❌ Limited budgets
- ❌ Single-brand strategy
- ❌ New market entry
- ✅ Better local SEO
- ✅ Keyword optimization per language
- ✅ Natural-looking URLs
- ✅ URLs make sense to local users
- ✅ More professional appearance
- ⚠️ Breaks existing links
- ⚠️ Requires 301 redirects
- ⚠️ More complex URL management
- ⚠️ Potential duplicate content if not configured correctly
- ✅ Enable for new sites
- ⚠️ Careful migration for existing sites
- ✅ Set up redirects from old URLs
- High: Sub-directory
- Very High + Local Markets: Custom domains
- Medium: Sub-domains
- Low/Testing: Query parameters
- Beginner: Sub-directory or Query parameter
- Intermediate: Sub-directory or Sub-domain
- Advanced: Sub-domain or Custom domain
- Limited: Sub-directory (single domain)
- Moderate: Sub-directory or Sub-domain
- High: Custom domains (multiple domains)
- Single brand: Sub-directory
- Regional variations: Sub-domain
- Completely localized: Custom domains
- New site: Any structure
- Existing site: Sub-directory (easiest migration)
- Large existing site: Careful planning needed
- Enable sub-directory structure:
- Set up 301 redirects:
- Update internal links
- Submit new sitemap to Google
- Monitor for issues (1-2 weeks)
- Remove old structure
- Plan thoroughly (affects DNS, SEO)
- Set up redirects on old sub-domains:
- Update all internal links
- Change hreflang tags
- Submit updated sitemap
- Monitor analytics and rankings (4-8 weeks)
- Keep redirects permanently
- SEO Settings
- URL Translation Setup
- Rewrite Rules
- Migration Guide
Technical Benefits:
User Experience:
Rewrite Rules
WordPress Automatically Handles:
`php
// Generated rewrite rules
example.com/es/about/
→ ?lang=es&pagename=about
example.com/fr/blog/article/
→ ?lang=fr&post_name=article
example.com/de/produkt/wallet/
→ ?lang=de&post_type=product&name=wallet
`
No Manual Configuration Needed
Default Language URL
Options for Default Language:
Option 1: No Language Prefix (Recommended)
`
English (default): https://example.com/about/
Spanish: https://example.com/es/about/
French: https://example.com/fr/about/
`
Option 2: Explicit Language Prefix
`
English (default): https://example.com/en/about/
Spanish: https://example.com/es/about/
French: https://example.com/fr/about/
`
Configuration:
`
Settings → SEO & URLs → Advanced
Default Language in URL:
● No prefix (recommended)
Example: /about/
○ Include prefix
Example: /en/about/
`
When to Use Prefix:
Sub-domain Structure
How It Works
URL Format:
`
English (default): https://www.example.com/about/
Spanish: https://es.example.com/about/
French: https://fr.example.com/about/
German: https://de.example.com/about/
`
Each Language = Separate Sub-domain
Configuration
Enable Sub-domain Structure:
`
Settings → SEO & URLs
URL Structure: [Sub-domain (es.site.com) ▼]
Sub-domain Configuration:
Main domain: example.com
Language sub-domains:
Automatic Setup: ☑ Configure DNS automatically (if supported)
Manual Setup: ☐ I will configure DNS manually
Save Changes
`
DNS Configuration
Required DNS Records:
Add these DNS records in your domain registrar:
`
Type | Host | Value | TTL
——|——|——————|—–
A | es | 123.45.67.89 | 3600
A | fr | 123.45.67.89 | 3600
A | de | 123.45.67.89 | 3600
CNAME | es | www.example.com | 3600
CNAME | fr | www.example.com | 3600
CNAME | de | www.example.com | 3600
`
Replace 123.45.67.89 with your server IP
Wildcard Sub-domains
Easier Management:
`
DNS Record:
Type: A
Host: *
Value: 123.45.67.89
TTL: 3600
Result: All sub-domains (*.example.com) point to same server
`
Server Configuration (Apache):
`apache
ServerName example.com
ServerAlias *.example.com
DocumentRoot /var/www/html
`
Server Configuration (Nginx):
`nginx
server {
listen 80;
server_name example.com *.example.com;
root /var/www/html;
}
`
Benefits
SEO Advantages:
Technical Benefits:
Scalability:
Limitations
Complexity:
SEO Considerations:
Maintenance:
Query Parameter Structure
How It Works
URL Format:
`
English (default): https://example.com/about/
Spanish: https://example.com/about/?lang=es
French: https://example.com/about/?lang=fr
German: https://example.com/about/?lang=de
`
Language via URL Parameter
Configuration
Enable Query Parameter Structure:
`
Settings → SEO & URLs
URL Structure: [Query Parameter (?lang=es) ▼]
Parameter Name: [lang]
Format: ?lang={language_code}
Examples:
?lang=es
?lang=fr
?lang=de
Save Changes
`
Benefits
Simplicity:
Compatibility:
Limitations
SEO Disadvantages:
User Experience:
Technical Issues:
When to Use
Acceptable For:
Not Recommended For:
Custom Domain Structure
How It Works
URL Format:
`
English: https://example.com/about/
Spanish: https://ejemplo.es/acerca-de/
French: https://exemple.fr/a-propos/
German: https://beispiel.de/uber-uns/
`
Each Language = Separate Domain
Configuration
Enable Custom Domain Structure:
`
Settings → SEO & URLs
URL Structure: [Custom Domain (country TLDs) ▼]
Domain Mapping:
┌──────────┬─────────────────────────────┐
│ Language │ Domain │
├──────────┼─────────────────────────────┤
│ English │ example.com (main) │
│ Spanish │ ejemplo.es [Edit] │
│ French │ exemple.fr [Edit] │
│ German │ beispiel.de [Edit] │
└──────────┴─────────────────────────────┘
[+ Add Domain Mapping]
WordPress Multisite: ☑ Required for this setup
Save Changes
`
WordPress Multisite Setup
Required:
Custom domains require WordPress Multisite.
Setup Steps:
`php
// wp-config.php
define(‘WPALLOWMULTISITE’, true);
`
`
Tools → Network Setup → Install
`
`php
// wp-config.php
define(‘MULTISITE’, true);
define(‘SUBDOMAIN_INSTALL’, false);
define(‘DOMAINCURRENTSITE’, ‘example.com’);
define(‘PATHCURRENTSITE’, ‘/’);
define(‘SITEIDCURRENT_SITE’, 1);
define(‘BLOGIDCURRENT_SITE’, 1);
`
`
Network Admin → Sites → Add New
Site URL: ejemplo.es
Language: Spanish
`
Install WordPress MU Domain Mapping or similar
DNS Configuration
For Each Domain:
`
Domain: ejemplo.es
DNS Records:
Type | Host | Value | TTL
——|——|—————-|—–
A | @ | 123.45.67.89 | 3600
A | www | 123.45.67.89 | 3600
Domain: exemple.fr
DNS Records:
Type | Host | Value | TTL
——|——|—————-|—–
A | @ | 123.45.67.89 | 3600
A | www | 123.45.67.89 | 3600
`
SSL Certificates
Option 1: Individual Certificates
`
example.com → SSL Certificate 1
ejemplo.es → SSL Certificate 2
exemple.fr → SSL Certificate 3
beispiel.de → SSL Certificate 4
`
Option 2: Multi-Domain SSL
`
One certificate covering:
`
Recommended: Let’s Encrypt (Free SSL for all domains)
Benefits
SEO Advantages:
Branding:
Limitations
Complexity:
Cost:
Technical:
SEO Challenges:
When to Use
Ideal For:
Not For:
URL Translation (Slug Translation)
Enable URL Translation
Translate URL Slugs:
`
Settings → SEO & URLs
☑ Enable URL translation
What gets translated:
☑ Page slugs
☑ Post slugs
☑ Category slugs
☑ Product slugs
☐ Tag slugs (optional)
Translation method:
● Automatic (Google Translate)
○ Manual only
`
Examples
Without URL Translation:
`
English: example.com/about-us/
Spanish: example.com/es/about-us/ (English slug)
French: example.com/fr/about-us/ (English slug)
`
With URL Translation:
`
English: example.com/about-us/
Spanish: example.com/es/acerca-de/ (Spanish slug)
French: example.com/fr/a-propos/ (French slug)
`
Manual Slug Override
Custom URL Slugs:
`
Edit Page: “About Us”
Permalink: /about-us/
ShahiTranslate Pro → URL Translation:
┌──────────┬──────────────────────────┐
│ Language │ URL Slug │
├──────────┼──────────────────────────┤
│ Spanish │ /acerca-de/ [Edit] │
│ French │ /a-propos/ [Edit] │
│ German │ /uber-uns/ [Edit] │
└──────────┴──────────────────────────┘
[Auto-Generate] [Save]
`
Benefits
SEO:
User Experience:
Risks
Technical:
Recommendation:
Choosing the Right Structure
Decision Framework
Question 1: What’s your SEO priority?
Question 2: What’s your technical expertise?
Question 3: What’s your budget?
Question 4: Multi-region strategy?
Question 5: Is site already live?
Recommendations
Most Businesses:
`
✅ Sub-directory structure
Why: Best SEO, easy setup, low cost
`
Large Enterprises:
`
✅ Sub-domain or Custom domain
Why: Scale, regional independence, infrastructure flexibility
`
Quick Prototype/Testing:
`
✅ Query parameter
Why: Fastest setup, no configuration
⚠️ Switch to sub-directory before launch
`
Local Market Focus:
`
✅ Custom domain (.es, .fr, .de)
Why: Local trust, SEO advantage
`
Migration Between Structures
From Query Parameter to Sub-directory
Safe Migration:
`
Settings → SEO & URLs → Sub-directory
/about/?lang=es → /es/about/
`
Redirect Code:
`php
function stpmigratequerytosubdirectory() {
if ( isset( $GET[‘lang’] ) && ! pregmatch( ‘#^/[a-z]{2}/#’, $SERVER[‘REQUESTURI’] ) ) {
$lang = sanitizetextfield( $_GET[‘lang’] );
$newurl = ‘/’ . $lang . $SERVER[‘REQUEST_URI’];
$newurl = removequeryarg( ‘lang’, $newurl );
wpredirect( $newurl, 301 );
exit;
}
}
addaction( ‘templateredirect’, ‘stpmigratequerytosubdirectory’ );
`
From Sub-domain to Sub-directory
Complex Migration:
`
es.example.com/page/ → example.com/es/page/
`
Next Steps
Share this article
Still need help?
Our support team is ready to assist you with personalized guidance for your workspace.