Skip to content
    Moz logo Menu open Menu close
    • Products
      • Moz Pro
      • Moz Pro Home
      • Moz Local
      • Moz Local Home
      • STAT
      • Moz API
      • Moz API Home
      • Compare SEO Products
      • Moz Data
    • Free SEO Tools
      • Domain Analysis
      • Keyword Explorer
      • Link Explorer
      • Competitive Research
      • MozBar
      • More Free SEO Tools
    • Learn SEO
      • Beginner's Guide to SEO
      • SEO Learning Center
      • Moz Academy
      • SEO Q&A
      • Webinars, Whitepapers, & Guides
    • Blog
    • Why Moz
      • Agency Solutions
      • Enterprise Solutions
      • Small Business Solutions
      • Case Studies
      • The Moz Story
      • New Releases
    • Log in
    • Log out
    • Products
      • Moz Pro

        Your all-in-one suite of SEO essentials.

      • Moz Local

        Raise your local SEO visibility with complete local SEO management.

      • STAT

        SERP tracking and analytics for enterprise SEO experts.

      • Moz API

        Power your SEO with our index of over 44 trillion links.

      • Compare SEO Products

        See which Moz SEO solution best meets your business needs.

      • Moz Data

        Power your SEO strategy & AI models with custom data solutions.

      NEW Keyword Suggestions by Topic
      Moz Pro

      NEW Keyword Suggestions by Topic

      Learn more
    • Free SEO Tools
      • Domain Analysis

        Get top competitive SEO metrics like DA, top pages and more.

      • Keyword Explorer

        Find traffic-driving keywords with our 1.25 billion+ keyword index.

      • Link Explorer

        Explore over 40 trillion links for powerful backlink data.

      • Competitive Research

        Uncover valuable insights on your organic search competitors.

      • MozBar

        See top SEO metrics for free as you browse the web.

      • More Free SEO Tools

        Explore all the free SEO tools Moz has to offer.

      NEW Keyword Suggestions by Topic
      Moz Pro

      NEW Keyword Suggestions by Topic

      Learn more
    • Learn SEO
      • Beginner's Guide to SEO

        The #1 most popular introduction to SEO, trusted by millions.

      • SEO Learning Center

        Broaden your knowledge with SEO resources for all skill levels.

      • On-Demand Webinars

        Learn modern SEO best practices from industry experts.

      • How-To Guides

        Step-by-step guides to search success from the authority on SEO.

      • Moz Academy

        Upskill and get certified with on-demand courses & certifications.

      • SEO Q&A

        Insights & discussions from an SEO community of 500,000+.

      Unlock flexible pricing & new endpoints
      Moz API

      Unlock flexible pricing & new endpoints

      Find your plan
    • Blog
    • Why Moz
      • Small Business Solutions

        Uncover insights to make smarter marketing decisions in less time.

      • Agency Solutions

        Earn & keep valuable clients with unparalleled data & insights.

      • Enterprise Solutions

        Gain a competitive edge in the ever-changing world of search.

      • The Moz Story

        Moz was the first & remains the most trusted SEO company.

      • Case Studies

        Explore how Moz drives ROI with a proven track record of success.

      • New Releases

        Get the scoop on the latest and greatest from Moz.

      Surface actionable competitive intel
      New Feature

      Surface actionable competitive intel

      Learn More
    • Log in
      • Moz Pro
      • Moz Local
      • Moz Local Dashboard
      • Moz API
      • Moz API Dashboard
      • Moz Academy
    • Avatar
      • Moz Home
      • Notifications
      • Account & Billing
      • Manage Users
      • Community Profile
      • My Q&A
      • My Videos
      • Log Out

    The Moz Q&A Forum

    • Forum
    • Questions
    • Users
    • Ask the Community

    Welcome to the Q&A Forum

    Browse the forum for helpful insights and fresh discussions about all things SEO.

    1. Home
    2. SEO Tactics
    3. Local SEO
    4. Local Website Optimization
    5. Image URLs changed 3 times after using a CDN - How to Handle for SEO?

    Moz Q&A is closed.

    After more than 13 years, and tens of thousands of questions, Moz Q&A closed on 12th December 2024. Whilst we’re not completely removing the content - many posts will still be possible to view - we have locked both new posts and new replies. More details here.

    Image URLs changed 3 times after using a CDN - How to Handle for SEO?

    Local Website Optimization
    2
    6
    2625
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as question
    Log in to reply
    This topic has been deleted. Only users with question management privileges can see it.
    • emerald
      emerald last edited by

      Hi Mozzers,
      Hoping for your advice on how to handle the SEO effects an image URL change, that changed 3 times, during the course of setting up a CDN over a month period, as follows:

      • (URL 1) - Original image URL before CDN:www.mydomain.com/images/abc.jpg
      • (URL 2) - First CDN URL (without CNAME alias - using WPEngine & their own CDN):
        username.net-dns.com/images/abc.jpg
      • (URL 3) - Second CDN URL (with CNAME alias - applied 3 weeks later):
        cdn.mydomain.com/images/abc.jpg

      When we changed to URL 2, our image rankings in the Moz Tool Pro Rankings dropped from 80% to 5% (the one with the little photo icons).

      So my questions for recovery are:

      • Do I need to add a 301 redirect/Canonical tag from the old image URL 1 & 2 to URL 3 or something else?
      • Do I need to change my image sitemap to use cdn.mydomain.com/images/abc.jpg instead of www.?

      Thanks in advance for your advice.

      1 Reply Last reply Reply Quote 0
      • RyanPurkey
        RyanPurkey @emerald last edited by

        Sorry I missed this follow-up earlier. Within the site map you'll want to change the http://WWW to http://CDN for these image files. The www version of your site, and the cdn server are on two different IPs / server. You want images to be serving from the CDN one.

        For 2, if you do use 301 redirection I'd recommend scripting it so that the script inspects whether or not it's an image file and then applies the cdn change. A pro in your area that works with REgex and htaccess will be able to guide you through that.

        The username.net-dns.com thing... That's not your server is it? You can't apply redirects on servers outside of your control.  Cheers!

        1 Reply Last reply Reply Quote 0
        • emerald
          emerald last edited by

          Hi Ryan,
          Thanks for your answer - Sorry I didn't mean about the URL for the location of the sitemap - I think my question wasn't clear - may I rephrase it:

          (1) Inside my image sitemap, the urls serve off the www. subdomain as bolded in the example below (not .cdn). I'm assuming this setup is correct as this was auto-generated by an Image Sitemap Generator - does the below image:loc look correct to you?

          <url><loc>http://www.bosphorusyacht.com/yachts/</loc>
          image:imageimage:lochttp://**WWW.**bosphorusyacht.com/wp-content/uploads/2010/09/istanbul-boat-rental.jpg</image:loc></image:image></url>

          (2) For a 301 image redirect would I set it up like this:

          Redirect 301 /wp-content/uploads/2010/09/istanbul-boat-rental.jpg
          http://**WWW.**bosphorusyacht.com/wp-content/uploads/2010/09/istanbul-boat-rental.jpg

          OR

          Redirect 301 /wp-content/uploads/2010/09/istanbul-boat-rental.jpg
          http://**CDN.**bosphorusyacht.com/wp-content/uploads/2010/09/istanbul-boat-rental.jpg

          OR

          How would I 301 this one?: username.net-dns.com/images/abc.jpg

          Hope you can advise one last time - thank you!

          RyanPurkey 1 Reply Last reply Reply Quote 0
          • RyanPurkey
            RyanPurkey @emerald last edited by

            Right. Not everything is going to be served from cdn. It's most likely setup for your images so your sitemap will still reside on www. Make sure to point to the front end files though as those are the publicly accessible ones.

            1 Reply Last reply Reply Quote 2
            • emerald
              emerald @RyanPurkey last edited by

              Hi Ryan,
              Thanks for your reply and advice. I've read the guidelines and will follow those. But I wonder if you can clarify an issue on implementing them that is not answered there:

              On my site the images in 'Backend' (edit/admin/code view) start with WWW.mydomain... and in 'Frontend' (actual published view in browser) they start with CDN.mydomain...

              So my question is, do I use the Backend or Frontend (www. or cdn.) for the URL in both image sitemaps and in 301 redirect final destination?

              My current sitemap for example seems to be using www rather than cdn. : http://www.bosphorusyacht.com/sitemap-image.xml

              Thanks for your help!

              RyanPurkey 1 Reply Last reply Reply Quote 0
              • RyanPurkey
                RyanPurkey last edited by

                You're on it. Redirecting to the new image source and submitting a new sitemap pointing to the URL 3 location for your images will be big steps in the right direction.  Be sure to follow the instructions here for your sitemap: https://support.google.com/webmasters/answer/178636 as well as reviewing image publishing guidelines: https://support.google.com/webmasters/answer/114016. Cheers!

                emerald 1 Reply Last reply Reply Quote 2
                • 1 / 1
                • First post
                  Last post

                Got a burning SEO question?

                Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.


                Start my free trial


                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.

                • See all categories

                Related Questions

                • Katarina-Borovska

                  International SEO - How do I show correct SERP results in the UK and US?

                  Hi, Moz community. I hope you’re all OK and keeping busy during this difficult period. I have a few questions about international SEO, specifically when it comes to ranking pages in the UK and the US simultaneously. We currently have 2 websites set-up which are aimed towards their respective countries. We have a ‘.com’ and a ‘.com/us’. If anybody could help with the issues below, I would be very grateful. Thank you all. Issues When looking in US Google search with a VPN, the title tag for our UK page appears in the SERP e.g. I will see: UK [Product Name] | [Brand] When checking the Google cache, the UK page version also appears This can cause a problem especially when I am creating title tags and meta descriptions that are unique from the UK versions However, when clicking through from the SERP link to the actual page, the US page appears as it should do. I find this very bizarre that it seems to show you the US page when you click through, but you see the UK version in the SERP when looking in the overall search results. Current Set-Up Our UK and US page content is often very similar across our “.com” and “.com/us” websites and our US pages are canonicalised to their UK page versions to remove potential penalisation We have also added herflang to our UK and US pages Query How do I show our US SERP as opposed to the UK version in US Google search? My Theories/ Answers US page versions have to be completely unique with content related to US search intent and be indexed separately - therefore no longer canonicalised to UK version Ensure hreflang is enabled to point Google to correct local page versions Ensure local backlinks point to localised pages If anyone can help, it will be much appreciated. Many thanks all.

                  Local Website Optimization | | Katarina-Borovska
                  0
                • BigChad2

                  Does having an embedded Google Map still count as a positive SEO signal?

                  I know this was true a few years ago, however is there still an advantage to having an embedded map vs. a pop up map in 2017?

                  Local Website Optimization | | BigChad2
                  1
                • TriMarkDigital

                  How to Handle Franchise Duplicate Content

                  My agency handles digital marketing for about 80 Window World stores, each with separate sites. For the most part, the content across all of these sites is the exact same, though we have slowly but surely been working through getting new, unique content up on some of the top pages over the past year. These pages include resource pages and specific product pages. I'm trying to figure out the best temporary solution as we go through this process. Previously, we have tried to keep the pages we knew were duplicates from indexing, but some pages have still managed to slip through the cracks during redesigns. Would canonicals be the route to go? (do keep in mind that there isn't necessarily one "original version," so there isn't a clear answer as to which page/site all the duplicated pages should point to) Should we just continue to use robots.txt/noindex for all duplicate pages for now? Any other recommendations? Thanks in advance!

                  Local Website Optimization | | TriMarkDigital
                  0
                • everestagency

                  Improving SEO with no blog

                  I have a client who understands the value of content for SEO - however getting them to provide some content has proven an impossible task. I've tried every way to make it easy for them. I've offered to come over to their office myself and see if I can just take 15 minutes of their time and record their answers to a few questions. The response is that's a great idea, we'll set up a time...and no time is ever good. So I've thought, what can I do without them? Unfortunately, their industry is so technical and so niche I'd need to have a law degree to even begin to understand exactly what they do, and as they are in law it's probably better to have no content than content with something even slightly incorrect in it. For now, all I can do is summarize and share news from a government website to their social media accounts. It's not highly effective. Their on-page SEO for the main site is completely optimized. I've placed them in every free listing I can possibly find - both industry and local sites. I have them update me on any local events, conferences and/or trade shows they attend for possible backlinks. What else can I do? I suppose I fear that if I can't provide them any additional results, they will stop seeing the value in SEO services, and I'd have a hard time disagreeing as I can't think of what else to do for them. Thanks for any help!

                  Local Website Optimization | | everestagency
                  1
                • Sean_Gutermuth

                  Can you, somehow, use dynamic number insertion on a click to call button (image)

                  Hello Moz! I have been beating my head against the wall for a few hours, and I am starting to get a headache. My question is simple: I am doing some work for a local salon, and we started a PPC campaign recently. It's very important that I get accurate ROI metrics from both our PPC efforts and Yelp advertising program, and the best way to do this is by using custom phone numbers and dynamic number insertion w/ CallRail to track phone calls being made to the salon. I can then cross reference the numbers used to call with the salon POS software to see what they spent, how many appts. they booked, etc. A VERY large portion, the majority in fact, of traffic comes from mobile, and in the past I had a big, fat, beautiful CTA click-to-call button that showed the salon phone number. However, I have found that with dynamic number insertion, and my near non-existent programming skills, it is impossible to have the number dynamically insert into an href image. Sooooo...any ideas on how to do this, or is it just not possible????

                  Local Website Optimization | | Sean_Gutermuth
                  0
                • otex

                  Should I use pipe in title tags for local seo?

                  Hi, I've created a bunch of landing pages for local areas, reading, windsor, slough etc for the title tag I have  for Windsor Emergency Electrician Windsor - BrandName should I be using a pipe in the tag to further help search engines learn/identify the location? Emergency Electrician | Windsor - BrandName Thank you Kev

                  Local Website Optimization | | otex
                  1
                • Adam_RushHour_Marketing

                  Subdomain for ticketing of a client website (how to solve SEO problems caused by the subdomain/domain relationship)

                  We have a client in need of a ticketing solution for their domain (let's call it www.domain.com) which is on Wordpress - as is our custom ticket solution.  However, we want to have full control of the ticketing, since we manage it for them - so we do not want to build it inside their original Wordpress install. Our proposed solution is to build it on tickets.domain.com.  This will exist only for selling and issuing the tickets. The question is, is there a way to do this without damaging their bounce rate and SEO scores?
                  Since customers will come to www.domain.com, then click the ticketing tab and land on tickets.domain.com, Google will see this as a bounce.  In reality, customers will not notice the difference as we will clone the look and feel of domain.com Should we perhaps have the canonical URL of tickets.domain.com point to www.domain.com? And also, can we install Webmaster Tools for tickets.domain.com and set the preferred domain as www.domain.com? Are these possible solutions to the problem, or not - and if not, does anyone else have a viable solution? Thank you so much for the help.

                  Local Website Optimization | | Adam_RushHour_Marketing
                  0
                • MiriamEllis

                  How Google's Doorway Pages Update Affects Local SEO

                  Hey Awesome Local Folks! I thought I'd take a proactive stance and start a thread on the new doorway pages update from Google, as I feel there will be questions coming up about this here in the forum: Here's the update announcement: http://googlewebmastercentral.blogspot.com/2015/03/an-update-on-doorway-pages.html And here's the part that will make local business owners and Local SEOs take a second glance at this: Here are questions to ask of pages that could be seen as doorway pages: Do the pages duplicate useful aggregations of items (locations, products, etc.) that already exist on the site for the purpose of capturing more search traffic? I think this will naturally lead to questions about the practice of creating local/city landing pages. At this point, my prediction is that this will come down to high quality vs. crummy quality pages of this type. In fact, after chatting briefly with Andrew Shotland, I'm leaning a bit toward seeing the above language as being strongly geared toward directory type sites and large franchises. I recommend reading Andrew's post about his take on this, as I think he's on the right track: http://www.localseoguide.com/googles-about-to-close-your-local-doorway-pages/ So, I'm feeling at this point that if you've made the right efforts to develop unique, high quality local landing pages, you should be good unless you are an accidental casualty of an over-zealous update. We'll see! If anyone has thoughts to contribute on this thread, I hope they will, and if lots of questions start coming up about this here in the community, feel free to link back to this thread in helping your fellow community members 🙂 Thanks, all!

                  Local Website Optimization | | MiriamEllis
                  9

                Get started with Moz Pro!

                Unlock the power of advanced SEO tools and data-driven insights.

                Start my free trial
                Products
                • Moz Pro
                • Moz Local
                • Moz API
                • Moz Data
                • STAT
                • Product Updates
                Moz Solutions
                • SMB Solutions
                • Agency Solutions
                • Enterprise Solutions
                Free SEO Tools
                • Domain Authority Checker
                • Link Explorer
                • Keyword Explorer
                • Competitive Research
                • Brand Authority Checker
                • Local Citation Checker
                • MozBar Extension
                • MozCast
                Resources
                • Blog
                • SEO Learning Center
                • Help Hub
                • Beginner's Guide to SEO
                • How-to Guides
                • Moz Academy
                • API Docs
                About Moz
                • About
                • Team
                • Careers
                • Contact
                Why Moz
                • Case Studies
                • Testimonials
                Get Involved
                • Become an Affiliate
                • MozCon
                • Webinars
                • Practical Marketer Series
                • MozPod
                Connect with us

                Contact the Help team

                Join our newsletter
                Moz logo
                © 2021 - 2025 SEOMoz, Inc., a Ziff Davis company. All rights reserved. Moz is a registered trademark of SEOMoz, Inc.
                • Accessibility
                • Terms of Use
                • Privacy

                Looks like your connection to Moz was lost, please wait while we try to reconnect.