Is it possible to 301 re-direct an entire subfolder on a subdomain?
-
So, for example,
subdomain.domain/folder
subdomain.domain/folder2
Is it possible to set up a 301-re-direct for an entire folder on a subdomain?
If so, how? What is the correct code for this?
-
This all depends on what your site is written in. We have an extensive guide for Apache, and in this post, Jen links to several other rewrites in different languages.
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
Technical 301 question
Howdy all, this has been bugging me for a while and I wanted to know the communities ideas on this. We have a .com website which has a little domain authority and is growing steadily. We are a UK business (but have a US office which we will be adapting too soon) We are ranking better within google.com than we do on google.co.uk probably down to our TLD. Is it a wise idea to 301 our .com to .co.uk for en-gb enquiries only? Is there any evidence that this will help improve our position? will all the link juice passed from 301s go to our .co.uk only if we are still applying the use of .com in the US? Many thanks and hope this isn't too complicated! Best wishes,
Intermediate & Advanced SEO | | TVFurniture
Chris0 -
What is better for web ranking? A domain or subdomain?
I realise that often it is better put content in a subfolder rather than a subdomain, but I have another question that I cannot seem to find the answer to. Is there any ranking benefit to having a site on a .co.uk or .com domain rather than on a subdomain? I'm guessing that the subdomain might benefit from other content on the domain it's hosted on, but are subdomains weighted down in any way in the search results?
Intermediate & Advanced SEO | | RG_SEO0 -
Setting up 301 Redirects after acquisition?
Hello! The company that I work for has recently acquired two other companies. I was wondering what the best strategy would be as it relates to redirects / authority. Please help! Thanks
Intermediate & Advanced SEO | | Colin.Accela0 -
How do you find all of your 301 redirects?
I would like a full list of 301 redirects that we have on our site. Is there a way to export it? I tried Bing Webmaster tools and the list was incomplete. We use IIS. Any ideas?
Intermediate & Advanced SEO | | EcommerceSite0 -
Can re-directs decrease your rankings??
Hi Guys, I need some advice here please - I have the chance to put some links on a few websites to my website in hope it will help with my rankings.. BUT - I have noticed that the webstites are being re-directed to another websites.. so my questions is ; Can re-driects decrease your rankings?? Thanks Gareth
Intermediate & Advanced SEO | | GAZ090 -
Subdomain or Subfolder for Locations?
I have a client who is ranking #1 for every term related to "bathroom renovations (main city)". They have now started to take on dealers/franchisees in neighbouring cities, and each location would now like to be ranking for THEIR cities. Is it better to use bathcompany.com/location or location.bathcompany.com? Considerations: The site has the address and phone number of the main location listed in the header, so if we do /location you will still see the main NAP. Using /location, If someone browses beyond the location landing page, they will venture into pages that target the main city (ex. "Bath Remodelling (Main City)") Using a subdomain will mean that we will need to duplicate content such as their image gallery, and we will have to create new content for their service pages or risk duplicate content. (ex. "shower remodelling (city)") Questions By using /location they will benefit from the strength of the subdomain, while using a new location-based subdomain will this mean we will have to start from scratch in terms of domain authority / link-juice? Will the NAP in the header affect the ranking of these location pages?
Intermediate & Advanced SEO | | ATMOSMarketing560 -
301 Redirect shenanigans.
So our website (www.FrontlineMobility.com) Has a canonical link redirect to the non www. version. However when I put in website.com it comes up with a small list of links and says this site links to www.website.com. So I'm curious if I used to wrong canonical linking method( that is the method I tried and I placed it in the Head Tags.) I greatly appreciate any assistance in this matter ^.^
Intermediate & Advanced SEO | | FrontlineMobility0 -
301 a page and then remove the 301
I have a real estate website that has a city hub page. All the homes for sale within a city are linked to from this hub page. Certain small cities may have one home on the market for a month and then not have any homes on the market for months or years. I call them "Ghost Cities". This problem happens across many cities at any point in time. The resulting city hub pages are left with little to no content. We are throwing around the idea of 301 redirecting these "Ghost City" pages to a page higher up in the hierarchy (Think state or county) until we get new homes for sale in the city. At that point we would remove the 301. Any thoughts on this strategy? Is it bad to turn 301s on and off like that? Thanks!
Intermediate & Advanced SEO | | ChrisKolmar0