How to move my blog from subdomain to subfolder?
-
Not an unusual situation, I have a blog on blog.domain.com it has quite a few blog postings. The platform is old and will be scrapped, but the blog content itself is going to be moved to domain.com/blog.
The current process is we are manually listing all linked to/content pages and we are going to 301 redirect them to their counterparts on the new blog. This is going to be a tedious process.
A) Is there any way to automate the moving of the blog?
B) What is the best way to do the massive 301 redirect, php headers, .htaccess? Should we move the individual pages with redirects, or redirect the domain in the .htaccess (this will be very difficult to match all the titles and file structure)?
-
Hi Keri.
You're right! I am not a professional in the matter and I am trying to catch up little by little.
Thanks for your advice!
-
This thread is actually four years old, and the original poster mentioned that the problem was solved so no worries! You might want to look at more recent questions, as SEO advice can change as the search engines change.
-
We solved it, our web programmer wrote a program to scrape all of our posts and turn them into a format that imported into wordpress. As far as the redirects we kept the page titles the same and did a sitewide 301 that sent them from blog.example.com to example.com/blog/
Although I would still like to grab Richard's php script for doing this in a more efficient manner in the future.
-
It will if you add r=301 to the last line like so:
RewriteRule ^(.*)$ /blog/$1 [L,R=301]
-
Spencer, did you get this taken care of off-line, or is this question still open?
[Keri Morgret, SEOmoz Associate]
-
Would you mind posting or messaging me the correct script? It would be a great help, thanks.
-
Yup, that will do the job of relocation, but it does not 301 the link and therefore you will not transfer link juice.
-
Found this one:
RewriteEngine On
RewriteCond %{HTTP_HOST} ^blog.mysite.com
RewriteRule ^(.*)$ /blog/$1 [L] -
I am mobile, so excuse the typos Using PHP, grab the incoming title and do a 301 header redirect to the new location. No need to mass 301 in .htaccess. If you need the script, let me know
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
-
How to safely syndicate blog posts in LinkedIn Company page
We currently post our new blog post on our company profile (in Linkedin) immediately after publishing on our company blog. Is this running the risk of duplicate content? My colleague pastes the new posts URL into (I've given an example using my own site - ironically about Panda)! Does this run the risk of creating duplicate content? I've tried searching for indexed pages in Google for past posts and only find the originals (no URLs for the LinkedIn domain). I've got a bit confused about the whole subject having read Neil Patel's excellent article on "...syndicating content without screwing up you seo"! Thank you 🙂 10FpxLP 10FpxLP
Technical SEO | | Catherine_Selectaglaze1 -
Blog on subdomain of e-commerce site
Hi guys. I've got an e-commerce site which we have very little control over. As such, we've created a subdomain and are hosting a WordPress install there, instead. This means that all the great content we're putting out (via bespoke pages on the subdomain) are less effective than if they were on the main domain. I've looked at proxy forwarding, but unfortunately it isn't possible through our servers, leaving the only option I can see being permenant redirects... What would be the best solution given the limitations of the root site? I'm thinking of wildcard rewrite rules (eg. link site.com/blog/articleTitle to blog.site.com/articleTitle) but I'm wondering if there's much of an SEO benefit in doing this? Thanks in advance for everyone's help 🙂
Technical SEO | | JAR8970 -
Is blog.example.com ok for seo benefits?
our blog is currently setup as blog.example.com is this OK for seo benefits for the main domain example.com? is there any benefit specifically for the domain level by having the blog set-up as example.com/blog? would it be worth the effort to do this on a large blog? thanks
Technical SEO | | Direct_Ram0 -
Infinite scroll blog
We're currently re-designing a website for our client, which includes an infinite scroll blog. When driving traffic to individual blog posts, is there a particular way to provide them with a unique URL to view the desired blog post? Thanks.
Technical SEO | | SymbiontGroup0 -
"Fourth-level" subdomains. Any negative impact compared with regular "third-level" subdomains?
Hey moz New client has a site that uses: subdomains ("third-level" stuff like location.business.com) and; "fourth-level" subdomains (location.parent.business.com) Are these fourth-level addresses at risk of being treated differently than the other subdomains? Screaming Frog, for example, doesn't return these fourth-level addresses when doing a crawl for business.com except in the External tab. But maybe I'm just configuring the crawls incorrectly. These addresses rank, but I'm worried that we're losing some link juice along the way. Any thoughts would be appreciated!
Technical SEO | | jamesm5i0 -
Different domains vs subdomains for 6 e-shops
We have to choose to stay working with different domain or move all 6 domains to new domain. Right now we have 6 different brand e-shops with 6 domains that have Domain Authority 30-40. So for example:
Technical SEO | | TauriUrb
e-shop1.com
e-shop2.com
.. And we are thinkig about making brand new domain and move all these domains content and link juice into one domain with 301 redirect. So we would have one e-shop solution with 6 subdomains like: e-shop1.newdomain.com
e-shop2.newdomain.com
... Like gap.com does with their brands or http://www.andotherbrands.com. That each brand has subdomains but they use same e-shop solution. With same domains or new subdomains strategy, we will improve internal linking structure between all these e-shops. We have also considerd that with new domain we don't have good organic search results within few first months. So we try to see the bigger picture and consider SEO future. SO QUESTION IS:
Lets leave brand marketing out, then what would you suggest to do? To stay with 6 different DA 30-40 domains or build one stong domain with 6 different brand subpages? We cant use subcategories. All subpages products will be clothes. Latetly there as beed many news and articles that subdomains are part of main domain and vice versa we are looking suggestions from this board. As we right now think that as we have weak domains righ now it would be better idea to start building one strong domain.0 -
How to redirect my .com/blog to my server folder /blog ?
Hello SEO Moz ! Always hard to post something serious for the 04.01 but anyway let's try ! I'm releasing Joomla websites website.com, website.com/fr, website.com/es and so on. Usually i have the following folders on my server [ROOT]/com [ROOT]/com/fr [ROOT]/com/es However I would like to get the following now (for back up and security purpose). [ROOT]/com [ROOT]/es [ROOT]/fr So now what can I do (I gues .htaccess) to open the folder [ROOT]/es when people clic on website.com/es ? It sounds stupid but I really don't know. I found this on internet but did not answer my needs. .htaccess RewriteEngine On
Technical SEO | | AymanH
RewriteCond %{REQUEST_URI} !(^/fr/.) [NC]
RewriteRule ^(.)$ /sites/fr/$1 [L,R=301] Tks a lot ! Florian0 -
Will errors on a subdomain effect the overall health of the root domain?
As stated in the question, we have 2 sub domains that contain over 2000 reported errors from SEOMOZ. The root domain has a clean bill of health, and i was just wondering if these errors on the sub-domains could have a negative effect on the root domain in the eyes of Google. Your comments will be appreciated. Regards Greg
Technical SEO | | AndreVanKets0