Subdomains & CDNs
-
I've set up a CDN to speed up my domain. I've set up a CNAME to map the subdomain cdn.example.com to the URL where the CDN hosts my static content (images, CSS and JS files, and PDFs).
www.example.com and cdn.example.com are now two different IP addresses.
Internal links to my PDF files (white papers and articles) used to be www.example.com/downloads but now they are cdn.example.com/downloads
The same PDF files can be accessed at both the www and the cdn. subdomain. Thus, external links to the www version will continue to work.
Question 1: Should I set up 301 redirects in .htaccess such as:
Redirect permanent /downloads/filename.pdf http://cdn.example.com/downloads/filename.pdf
Question 2: Do I need to do anything else in my .htaccess file (or anywhere else) to ensure that any SEO benefit provided by the PDF files remains associated with my domain?
Question 3: Am I better off keeping my PDF files on the www side and off of the CDN?
Thanks,
Akira
-
On your cdn, you have an option to disallow se's to index files on subdomains by robots.txt so you can keep a copy on cdn.example.com as well, and noindex it via robots.txt for better user experience
-
Yup...keep it simple...where possible
-
There are about a dozen PDFs and they are indexed.
I agree that it's probably better to play it safe and keep these files on www.
Thanks!
-
How many PDF files are we talking ? Are they indexed ? Is there unique text content or images that have text that google has OCR'D ? If yes, I would suggest keeping them on www and therefore keep it simple. Again, it depends how many PDF files in number as well as their size in gigs would make it an easy answer.
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
-
Subdomain or subfolder?
Hello, We are working on a new site. The idea of the site is to have an ecommerce shop, but the homepage will be a content page, basically a blog page.
Technical SEO | | pinder325
My developer wants to have the blog (home) page on a subdomain, so blog.example.com, because it will be easier to make a nice content page this way, and the the rest of the site will just be on the root domain (example.com). I'm just worried that this will be bad for our SEO efforts. I've always thought it was better to use a sub folder rather than a subdomain. If we get links to the content on the subdomain, will the link juice flow to the shop, on the root domain? What are your thoughts?0 -
SEO & IFrame problem
Hi All, I will try and keep this as simple as possible. My product page links to a separate page with an IFrame, giving my users the option to upload artwork for the product. The IFrame contains the external file upload site (mail big file). When finished, the user can use a button link to return to the product page to continue with their order. As soon as the page with the IFrame was crawled by Google, the IFrame page started to rank in place of where my product page used to rank, yet there is no content on the page relating to my product (just a file upload). So now users are visiting the IFrame via the same query which must be an absolute headache and not useful at all. I have tried the following: 1. Added a line in body text which contains an internal link pointing to the product page using exact match anchor text for the query. (This didn't work) 2. I applied a no index tag to the IFrame, and now my product page is no longer ranking at all. Can anyone help me solve this puzzle. I believe I might be missing something. Kind regards, Adam
Technical SEO | | SO_UK0 -
Removed Subdomain Sites Still in Google Index
Hey guys, I've got kind of a strange situation going on and I can't seem to find it addressed anywhere. I have a site that at one point had several development sites set up at subdomains. Those sites have since launched on their own domains, but the subdomain sites are still showing up in the Google index. However, if you look at the cached version of pages on these non-existent subdomains, it lists the NEW url, not the dev one in the little blurb that says "This is Google's cached version of www.correcturl.com." Clearly Google recognizes that the content resides at the new location, so how come the old pages are still in the index? Attempting to visit one of them gives a "Server Not Found" error, so they are definitely gone. This is happening to a couple of sites, one that was launched over a year ago so it doesn't appear to be a "wait and see" solution. Any suggestions would be a huge help. Thanks!!
Technical SEO | | SarahLK0 -
<sub>& <sup>tags, any SEO issues?</sup></sub>
Hi - the content on our corporate website is pretty technical, and we include chemical element codes in the text that users would search on (like S02, C02, etc.) A lot of times our engineers request that we list the codes correctly, with a <sub>on the last number. Question - does adding this code into the keyword affect SEO? The code would look like SO<sub>2</sub>.</sub> Thanks.
Technical SEO | | Jenny10 -
Is a shorter subdomain better?
For example, consider the two subdomains below: learn.bluelinkerp.com learnmore.bluelinkerp.com Would there likely be an appreciable difference between the two based on length alone? Also, would it be better to use a term that relates to our product in general such as "software.bluelinkerp.com"? Thanks!
Technical SEO | | BlueLinkERP0 -
Is submitting your site to yahoo & Google still relevant
Good Morning from Sh@t its still raining wetherby UK... I want to just make sure the process i go through when a new site is launched is nort overlooking some fundamentals. Most sites we launch are not brand new, do allready have a link heritage and have been indexed by Google. With that in mid i do not submit a sites url thru the following links: www.google.com/addurl
Technical SEO | | Nightwing
search.yahoo.com/info/submit.html
search.live.com/docs/submit.aspx Am i right in saying you should really only bother with this if the site a newbie ie no history no link heritage and the site is enering cyberspace for the forst time. And i wonder if for example you launched a new site made sure the xml site map was in place and it had a few inbound links anyway it would be indexed anyway. So is the practice of submitting your url to search engined relevant anymore? Any insights welcome 🙂2 -
E-commerce solution and subdomain issues
Hello All,
Technical SEO | | CherieP
In light of Wil Reynold's closing keynote at Portland's Searchfest, I thought I might try posting here to get some advice. We run a family business on the side and we're looking at starting to use volusion.com for our e-commerce solution. The catch is we currently have a wordpress site summitmining.com running on thesis with great SEO. Ranking #1 & #2 for our highest trafficked terms. Ideally, I'd like Summitmining.com to direct to the Volusion store and then summitmining.com/blog to go to our wordpress installation BUT since the volusion site will be hosted with the company and they will not host our wordpress installation we'd have to use a subdomain instead of a subdirectory which I understand will be bad for SEO. Does anyone have any recommendation on how to set this up without totally screwing up our ranking OR any recommendations of an easy to use shopping cart (I've worked on a magento site before and it's too complex for us) that wouldn't require a separate or subdomain? Thank you so much!
-Cherie Prochaska
503-816-3557
cherie@c-squaredassociates.com
@cherieprochaska0 -
Removing duplicate &var=1 etc var name urls from google
Hi I had a huge drop in traffic around the 11th of july over 50% down with no recovery as yet... ~5000 organic visits per day down to barley over 2500. I fixed up a problem that one script was introducing that had caused high bounce rates. Now i have identified that google has indexed the entire news section 4 times, same content but with var=0 var=1 2 3 etc around 40,000 urls in total. Now this would have to be causing problems. I have fixed the problem and those url's 404 now, no need for 301's as they are not linked to from anywhere. How can I get them out of the index? I cant do it one by one with the url removal request.. I cant remove a directory from url removal tool as the reuglar content is still there.. If I ban it in robots.txt those urls, wont it never try to index them again and thus not ever discover they are 404ing? These urls are no longer linked to from anywhere, so how can google ever reach them by crawling to find them 404ing?
Technical SEO | | Adsau0