The Moz Q&A Forum

    • Forum
    • Questions
    • My Q&A
    • Users
    • Ask the Community

    Welcome to the Q&A Forum

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

    1. SEO and Digital Marketing Q&A Forum
    2. Categories
    3. Link Building
    4. Redirect 301 multiple url to frontpage

    Redirect 301 multiple url to frontpage

    Link Building
    3 2 211
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as question
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Morten-Hjemmesider
      Morten-Hjemmesider last edited by

      I have a lot of /dummy.php/xxx pages that i would like to redirect to the front page.

      /dummy.php/100
      /dummy.php/101
      /dummy.php/102
       .....

      redirect 301 /dummy.php/WILDCARD http://www.domain.com

      I can not figure it out?

      1 Reply Last reply Reply Quote 0
      • customerparadigm.com
        customerparadigm.com last edited by

        I would test this, and it might work differently according to your server setup, but you could try the RedirectMatch command like this if your site uses mod_alias:

        RedirectMatch 301 ^/dummy.php/.*$ http://www.domain.com/

        Or with mod_rewrite, this might be the way to go:
        RewriteRule ^dummy.php/ http://www.domain.com/ [R=301,L]

        I hope this helps!
        -- Jeff

        1 Reply Last reply Reply Quote 1
        • Morten-Hjemmesider
          Morten-Hjemmesider last edited by

          Super Jeff

          You saved my day 🙂

          1 Reply Last reply Reply Quote 0
          • 1 / 1
          • First post
            Last post
          • Should my URLs with or without a slash? And how to avoid multiple redirects?
            jessential
            jessential
            0
            3
            598

          • 301 redirect single page
            benesmartin
            benesmartin
            0
            4
            377

          • MOZ indicates 404 page and 0 backlinks, after 301 redirect. The best redirect solution?
            Chemometec
            Chemometec
            0
            7
            300

          • 301 redirect on yahoo hosting
            jimmy0225
            jimmy0225
            0
            6
            2.8k

          • Same Page, Multiple URLS- Canonical tag? Redirect?
            Telikin
            Telikin
            0
            3
            1.2k

          • 301 permanent redirects, is good for SEO?
            simplesm
            simplesm
            0
            5
            435

          • Domain buyouts and 301 redirects
            Highland
            Highland
            0
            2
            310

          • 301 Redirect Domains with old links
            RyanKent
            RyanKent
            0
            3
            828

          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
          • Digital Marketers
          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 - 2026 SEOMoz, Inc., a Ziff Davis company. All rights reserved. Moz is a registered trademark of SEOMoz, Inc.
          • Accessibility
          • Terms of Use
          • Privacy