↪️
Domains

Domain Forwarding: Redirect Types and When to Use Each

11.11.2026
← All articles

Domain forwarding sends a visitor who opens one address automatically to another. You need it when a company rebrands, buys a short domain for advertising, or moves an old site to a new one. There are several redirect types, though, and the wrong choice can cost search rankings, trigger security warnings or break pages on phones.

Forwarding is a web server job, not DNS

DNS only tells the browser which IP address a domain belongs to; it cannot say "go somewhere else". The redirect itself comes from a web server, which answers with an HTTP status code and a Location header. So the forwarded domain must still point to a server. A "forwarding" button in any control panel simply creates such a server rule behind the scenes.

The types at a glance

TypeMeaningTypical use
301Permanent moveRebrand, domain change, www/HTTPS consolidation
302Temporary moveShort promotion, maintenance page
307Temporary, method preservedForms and APIs where POST must stay POST
308Permanent, method preservedPermanently moving an API endpoint
MaskedAddress bar unchanged, content in a frameRarely, not recommended

301 for permanent changes

A 301 tells browsers and search engines that the old address has been replaced for good, so over time the index and link value move to the new one. Suppose a private clinic in Tashkent moves from shifo-klinika.uz to yangi-shifo.uz. It should keep the old domain for years with a 301, or patients using old business cards will hit a dead end and years of rankings will vanish. Map each old page to its new equivalent rather than dumping everything on the home page:

# .htaccess on the old domain
RewriteEngine On
RewriteRule ^(.*)$ https://yangi-shifo.uz/$1 [R=301,L]

# pages whose URL changed (place before the general rule)
Redirect 301 /doktorlar.html https://yangi-shifo.uz/shifokorlar/

302 and 307 for temporary situations

Temporary redirects keep the original URL in the index. Use them for a holiday campaign or a maintenance notice. Using 302 for a permanent move is a common mistake that leaves the old address indexed for a long time. A 307 behaves like 302 but forbids changing the request method, which matters for form submissions and APIs, since some clients turn POST into GET after a 302. Its permanent counterpart is 308. In nginx:

location = /katalog {
    return 302 https://dokon.uz/aksiya/;
}

server {
    listen 80;
    server_name eski-dokon.uz www.eski-dokon.uz;
    return 301 https://dokon.uz$request_uri;
}

Why masked forwarding causes trouble

Masked or frame forwarding keeps the old domain in the address bar while loading another site in an invisible frame. Search engines do not credit the content to the masking domain, many sites block framing with X-Frame-Options or Content-Security-Policy and show a blank page, the URL never changes so links cannot be shared, and mobile layouts often break. Use it only when nothing else is possible.

Do not forget HTTPS and email

Browsers increasingly open https:// by default. If the old domain has no certificate, visitors see a security warning before the redirect is ever sent, because the TLS handshake for that exact name must succeed first. Keep the old domain on your hosting with its own certificate; on sayt.uz hosting Let's Encrypt certificates are free and renew automatically. Web forwarding also does nothing for email: keep the old domain's MX records and set up an alias or forwarding rule so messages to info@shifo-klinika.uz still arrive.

Test it properly

Browsers cache 301 responses aggressively, so check from the command line:

curl -sIL http://shifo-klinika.uz/doktorlar.html | grep -iE "^(HTTP|location)"

The -L flag follows the whole chain, exposing unnecessary hops. JavaScript or meta refresh redirects are slower and less reliably understood by crawlers, so keep them for cases with no server access at all. In short: 301 for permanent moves, 302 or 307 for temporary ones, avoid masking, and remember the certificate and mail settings of the old domain.

Related articles

🛡️ Multiple Domains for an Organization: Building a Defensive Set 🔢 Numbers and hyphens in a domain name: pros and cons 📅 How Many Years to Register a Domain For: 1, 3 or 5 🎭 Domain masking: why it hurts SEO and what to use instead
🌐 Language
🇺🇿 O'zbek 🇺🇿 Ўзбек 🇷🇺 Русский 🇬🇧 English ✓