Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [301-redirect]

The HTTP response status code 301 Moved Permanently is used for permanent redirection. This status code should be used with the location header.

1
vote
1answer
19 views

How to debug big redirect chain in nginx. Unexpected redirect

I have a task to make a large site migration now. And i have a large number of redirects in config. But I cannot understand why one redirect causing second redirect in chain. Even if any other ...
0
votes
1answer
21 views

nginx server configuration to redirect all requests to ssl without subdomain

I want to redirect all requests to example.org. I created a configuration file as below. I can redirect the requests from : http anything.example.org to https example.org https anything.example.org ...
0
votes
0answers
28 views

Nginx Redirect Loop in a Letsencrypt Docker with Multiple Sites

I am getting a "too many redirect error" when I try to go to my own websites. Those websites are hosted on my server with Nginx inside a Letsencrypt Docker(Docker Hub: https://hub.docker.com/r/...
0
votes
1answer
21 views

NGINX: Cannot config nginx to handle redirect from HTTP to HTTPS redirect not working

I have try to config nginx: /etc/nginx/nginx.conf server { listen 80 default_server; listen [::]:80 default_server; server_name 10.0.0.10; #This is my private IP return 301 https://$...
0
votes
0answers
13 views

Apache HSTS with non-www to www 301 redirect

Just been setting up HSTS on an Apache vHost (it is a virtualmin box) and have that working, however I am experiencing strange behavior when trying to force a call to https www rather than it ...
0
votes
1answer
65 views

SSL Certificate, Redirect, No-www done right (apache)?

MY GOAL I would like to make a website accessible only via SSL (encrypted) and with many domains redirecting to only one master domain (no duplicate content) and all www variants should be no-www. ...
0
votes
0answers
20 views

New domain to redirect to one hosted elsewhere without SEO damage

The goal is to rebrand a website and use a new domain for that website. The old domain should redirect to the new domain with at least negative SEO impact as possible. Hosting A is where the both the ...
1
vote
0answers
21 views

Removing nginx server_name results in too many redirects

I'm trying to test out a new website before replacing the original one, since I don't want to impact users. I have an existing website at say example.com and am working on a separate WordPress site ...
0
votes
1answer
41 views

NGINX SSL “ERR_TOO_MANY_REDIRECTS”

I have website build with django and nginx. After adding Let's Encrypt SSL certificat using Certbot I get the error : ERR_TOO_MANY_REDIRECTS. Please find the below nginx configuration : server { ...
0
votes
0answers
44 views

HTTPS + IP not redirecting to configured Domain Name and gives “Your connection is not private” [Nginx/Ubuntu]

I am using NGINX for 301 redirects on Ubuntu and reverse proxy for my Web Application and aim is to redirect traffic to non-www url such as https://mywebapplication.example. So with my current ...
1
vote
1answer
42 views

Mapping Old to new URL is not working in Nginx

I am moving my old Url's to the new one (it is more than 50) so I have placed the URLs in a file but the redirection is not happening. map_hash_max_size 262144; map_hash_bucket_size 262144; map $uri ...
1
vote
1answer
180 views

Editable URL Rewrite Map for CloudFront/S3 Website using Lambda@Edge

I'm migrating a static website from IIS to Amazon S3, using CloudFront for https. The old site used the URL Rewrite module and had 301 redirect maps with over 200 entries. Here is an example: example....
0
votes
1answer
62 views

Redirect with space character for file download

I have this in the .htaccess file: Redirect 301 /product-installer https://download.testsite.com/installers/My%20Product%20v3.0.0.0.exe It's working correctly of Firefox as when you click the URL ...
1
vote
1answer
133 views

301 Redirect all child pages to parent page with the exception of a few child pages to other pages throughout the site

How would I go about 301 Redirecting all child pages to the parent page with the exception of a few child pages 301 Redirected to other specific pages throughout my site. Below works for redirecting ...
0
votes
1answer
44 views

Nginx HTTPS redirect loop with multiple domains

I know that there are other questions with similar topics, but I can't find a solution anywhere that solves my specific problem. The difference here is multiple domains with different sites. I have ...
1
vote
1answer
107 views

redirect dynamic url to subdomain

I am trying to redirect the URL to the corresponding subdomain. For example: example.com/account/user example.com/account/user2 to user.example.com user2.example.com I have tried: Redirect /...
0
votes
2answers
232 views

Unable to remove 301 redirect for wordpress wp-admin on nginx

Unable to remove 301 redirect for wordpress wp-admin on nginx. The homepage seems fine I’ve tried almost everything Disabling plugins by renaming the plugin directory Removing the ...
1
vote
1answer
65 views

.htaccess 301 redirect remove [] from the URL

I want to remove '[' and ']' from the URLs and redirect to correct link. Here is a sample URL: /forums/garage-150/cool-cars-sightings-[archived]-7610/index127.html Needs to be redirected to: /...
1
vote
1answer
203 views

Apache Redirect to /index.php - How to handle direct requests for /index.php

I'm not 100% sure if this should be on server fault or stack overflow, though I'm leaning towards server fault. Most PHP frameworks utilize Apache redirects to funnel all request to /index.php and ...
0
votes
1answer
46 views

How to redirect all requests except when there's an exact string match

Requirement- I want to redirect all requests that end with /abcd to /products/abcd This should match all urls such as these- /collection/abcd /collections/all/abcd /hello/world/abcd This is what i'...
0
votes
1answer
52 views

Apache: Is the password protection in a .htaccess file always processed first?

Last week I did a relaunch on a website and today I have realized that the staging subdomain got indexed by Google. I want to avoid this mistake in the future and track down the error source. I ...
1
vote
0answers
52 views

301 redirect on IIS with optional query string

I have a working 301 redirect setup for languages that looks like this: <rule name="mygreatrule" stopProcessing="true"> <match url="^productname" /> <conditions logicalGrouping=...
0
votes
2answers
82 views

How to certify a domain that's used only for redirections and has no hosting?

I migrated a site from oldsite.example to newsite.example. HTTPS was enforced all over, so most incoming links to oldsite are going to https://www.oldsite.example. My oldsite.example domain used to ...
0
votes
1answer
34 views

NGINX configuration for creating a shortlink service from existing shortlink web service

I have an existing shortlink service with long domain name longname.com/Wsdfsdf . When the visitor clicks this link it redirects to longname.com/order-details/customer-id/3435345345435 Now I have a ...
0
votes
0answers
44 views

Linode Longview Apache https Redirect

I have setup Linodes longview (which is used to view your servers information from the linode dashboard). All is working apart from the Apache tab, which gives the following error: Unable to access ...
0
votes
2answers
149 views

Redirect root to www nginx on HTTPS

Here is the current status: http://example.com to https://www.example.com works http://www.example.com to https://www.example.com works https://example.com to https://www.example.com DOESN'T redirect ...
1
vote
1answer
57 views

Redirect with query stings

I have a very annoying redirect I cannot figure out. I have many hundreds of page like the below: example.com/directory/in.php?url_id=28930 I want to redirect all e.g. /directory/in.php?url_id=...
0
votes
1answer
78 views

How can I bootstrap certbot on a hard-redirecting https domain?

I have a working Nginx config that: Performs a hard-redirect (301) from http to https Additionally, ignores subpaths on http (http://www.example.com/ANY/THING redirects to plain https://example.com) ...
-2
votes
1answer
84 views

Redirect my https://123.456.567.789 to https://example.com || Nginx [closed]

I want to create redirection rule for my site, i want to redirect my site from ip to domain, but its working fine in non-https , but when i type https://id-address it opens as it is, no redirection. ...
0
votes
1answer
39 views

Trying to forward an HTTPS URL to another

The domain ultimateedgeapparel.com is registered on GoDaddy and I've setup a 301 redirect through GoDaddy's forwarding service to this page - https://www.allvolleyball.com/ultimate-edge which works. ...
0
votes
1answer
206 views

Nginx server redirect loop after SSL

So i've had some problems getting SSL to work on my Nginx server. After some time trying and following tutorials i've finally got it to work. Then when i wanted to access the hipchat server i got ...
1
vote
2answers
115 views

apache2 mod_rewrite redirect without http body [duplicate]

I am currently using Apache mod_rewrite to redirect to HTTPS, but I would like to remove the body from the response. How it is currently: Example: How I would like it to be My redirect ...
-1
votes
1answer
2k views

Apache Rewrite redirect all pages except for specific [duplicate]

I am retiring a site and would like to display a message when anyone tries to access any page on the site EXCEPT for a couple of pages. Some pages have certain pageid parameters. So basically ...
0
votes
0answers
44 views

map setting is not working for redirect in nginx

I have redirect-map.map file which has some url to redirect as below but redirect setting is not working: /jewelry/test/costumes(.*)a1 https://test.com/jewelry/test/costumes.html; /jewelry/test/...
1
vote
0answers
64 views

Is there a way i can track which IIS server redirects are being used

Our web.config file has 1300 redirects in it and growing all the time. Its a mixture of 4 site rebuilds over 15 years and marketing vanity URLS. My question is 3 part. does having to search through ...
0
votes
1answer
769 views

Nginx 301 domain redirect not working

I am trying to redirect (or I guess forward) my old domain (example.com) to my new domain (example2.com) now that I have updated my server config to accommodate the new domain. However, it doesn't ...
0
votes
0answers
10 views

Redirection htaccess code headache

Can anyone help me figure this out? I want to re-direct my example.com & example.com/index.html & http://www.example.com to https://www.example.com I tried this code but I think it's re-...
1
vote
0answers
22 views

Apache settings to prevent browser from redirect

I have a question regarding redirects. We currently have set up an Apache with a wildcard certificate *.shopdomain.com and run different shops on different subdomains like shop-a.shopdomain.com, shop-...
1
vote
2answers
923 views

How to redirect specific pages in htaccess, and all other redirect to the homepage?

How do I 301 specific pages to a new domain URI, and then all the rest of the pages, just send to the homepage? Example -- Specific pages I want to move -- Redirect 301 /contact.htm https://...
0
votes
1answer
64 views

Google Compute resize gives: HTTP/1.0 301 Moved Permanently

I recently installed a Wordpress instance on Google's Compute Engine with Google's own one-click install button. It doesn't let you configure the server or OS so I just took what Google offered (...
3
votes
1answer
44 views

Apache htaccess redirect?

I have a client who has a domain like this-site.com and also thissite.com Without going into the entire issue behind it, we need to redirect any incoming request to any *.this-site.com to the matching ...
1
vote
1answer
295 views

nginx and redirection from another domain

So I have www.old-domain.com and we've just transferred to www.new-domain.com old-domain.com's server had an SSL certificate and could handle both http://www.old-domain.com and https://old-domain.com ...
1
vote
1answer
2k views

.htaccess redirect all domains, with paths, to one

I have three domains all pointing to the same hosting space, mirrored using A records: example.org example.org.uk example.co.uk I have a website on the root (/), and a MediaWiki installation at ...
12
votes
2answers
17k views

Best way to redirect all HTTP to HTTPS in IIS

We want ALL sites on our webserver (IIS 10) to enforce SSL (ie redirect HTTP to HTTPS). We are currently 'Requiring SSL' on each site and setting up a 403 error handler to perform a 302 redirect to ...
1
vote
0answers
296 views

Windows web config redirect, different folder name and domain

I have 2 websites and a few thousands links with the same pattern that need to be redirected. I want to achieve this by writing the code one time and for it to work for all of the URLs. This is the ...
-2
votes
1answer
240 views

how to redirect old html url to new php Url [duplicate]

How to redirect old html page to new php page. I used this code but it redirecting with full file path. I'm using below code. RewriteEngine On RewriteRule ^(.*).html$ $1.php
0
votes
1answer
310 views

NGINX 301 list of redirects SEO

I have about 250 URLS that need to be redirected from an old site to new. In the server block I set this statement: include /etc/nginx/301s/somesite.conf; Then in the included file I have a list of ...
0
votes
1answer
129 views

Unwanted 301 Redirect for new VirtualHost for subdomain

For the last 3 years I've had 2 copies of my Wordpress website. One at www.domain.com and one at dev.domain.com. I'm trying to add a third today. Seems simple enough! I go through all the simple setup ...
0
votes
1answer
1k views

Redirect naked domain to www with SSL in cloudfront/route 53

I have setup two buckets on s3 one for my actual angular 2 app: www.example.com and one for redirecting example.com to www.example.com. I have also created two distributions in cloud front and added a ...
1
vote
1answer
1k views

CNAME redirect to external https url

I have a somehow specific setup. It really is due to some restrictions I cannot work around: There are domains 1. and 2. which I own and an external URL which I don't own: start.com root.com http://...