undefined
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.

    • MozCon

      Save on Early Bird tickets and join us in London or New York City

    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. Intermediate & Advanced SEO
  4. Where to put a page ID in a URL?

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.

Where to put a page ID in a URL?

Intermediate & Advanced SEO
3
5
3.8k
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.
  • komeksimas
    komeksimas last edited by Jan 17, 2013, 12:23 PM

    Hello,

    My company is going to change URLs to example.com/category or example.com/product.

    When we will change the URLs to product or category pages somehow we have to check whether the requested page is from category table in DB or from products table (this gives much speed to page load time).

    So we have to choose how to make the different product and category pages.
    Programmers said that we need to insert id to URL.

    So the question is: Which is the better way to place an id to an URL?

    example.com/product-name?id=111

    example.com/product-name/111

    example.com/product_name-111

    Or maybe we should use some other punctuation mark to separate id from product name?

    p.s. I have read Dynamic URLs vs. static URLs by Google and it still didn't answered which is the best for all of the pages.

    Somehow others solve this problem by typing only the names to the URL, but could anyone tell what that technology should be?

    1 Reply Last reply Reply Quote 0
    • komeksimas
      komeksimas @ske11 last edited by Jan 18, 2013, 6:33 AM Jan 18, 2013, 6:33 AM

      As I have seen somewhere that underscore "_" unites the names and Google looks at it like one word with no spaces.

      Wouldn't it be bad for long product names?

      example.com/2010_chrysler_grand_voyager_2l would be the same as write example.com/2010chryslergrandvoyager2l ?

      1 Reply Last reply Reply Quote 0
      • komeksimas
        komeksimas @Highland last edited by Jan 31, 2013, 7:18 AM Jan 18, 2013, 6:21 AM

        Just trying to get the best out of everything 🙂

        In this case, doesn't product-name-111 is all keywords for a page? My product if my product page doesn't consist of 111 it would make a mess for Google.

        I can give one example that could messes up:
        example.com/cars-1963

        And 1963 isn't a year nor it's a model number of a car, it's the ID of a catalog.

        1 Reply Last reply Reply Quote 0
        • Highland
          Highland last edited by Jan 17, 2013, 1:03 PM Jan 17, 2013, 1:03 PM

          I would select a modified option #3 (modified in that I used all dashes)

          example.com/product-name-111

          I've seen this work. VBSEO (a vBulletin forum plugin that rewrites URLs) uses this format, where the ID is at the end of the URL. I've not seen any ill effects and this plugin has used this format for years.

          Don't get too hung up on the URL structure. It's like worrying about what color to paint your walls when your house has structural issues. URLs are window dressing. They help SEO, but only slightly.

          komeksimas 1 Reply Last reply Jan 18, 2013, 6:21 AM Reply Quote 0
          • ske11
            ske11 last edited by Jan 17, 2013, 12:55 PM Jan 17, 2013, 12:55 PM

            I would use example.com/product_name-111

            I believe you need to do a mod re-write to get the URL to display the way you want it, but others will be better placed to advice you on this than I am.

            komeksimas 1 Reply Last reply Jan 18, 2013, 6:33 AM Reply Quote 0
            • 1 / 1
            1 out of 5
            • First post
              1/5
              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

            • shabbirmoosa

              Rel canonical tag from shopify page to wordpress site page

              shopify wordpress canonical

              We have pages on our shopify site example - https://shop.example.com/collections/cast-aluminum-plaques/products/cast-aluminum-address-plaque That we want to put a rel canonical tag on to direct to our wordpress site page - https://www.example.com/aluminum-plaques/ We have links form the wordpress page to the shop page, and over time ahve found that google has ranked the shop pages over the wp pages, which we do not want. So we want to put rel canonical tags on the shop pages to say the wp page is the authority. I hope that makes sense, and I would appreciate your feeback and best solution. Thanks! Is that possible?

              Intermediate & Advanced SEO | Jan 31, 2024, 4:19 PM | shabbirmoosa
              0
            • viatrading1

              Merging Pages and SEO

              Hi, We are redesigning our website the following way: Before: Page A with Content A, Page B with Content B, Page C with Content C, etc
              e.g. one page for each Customer Returns, Overstocks, Master Case, etc
              Now: Page D with content A + B + C etc.
              e.g. one long page containing all Product Conditions, one after the other So we are merging multiples pages into one.
              What is the best way to do so, so we don't lose traffic? (or we lose the minimum possible) e.g. should we 301 Redirect A/B/C to D...?
              Is it likely that we lose significant traffic with this change? Thank you,

              Intermediate & Advanced SEO | Oct 2, 2016, 2:48 PM | viatrading1
              0
            • andyheath

              Magento: Should we disable old URL's or delete the page altogether

              Our developer tells us that we have a lot of 404 pages that are being included in our sitemap and the reason for this is because we have put 301 redirects on the old pages to new pages. We're using Magento and our current process is to simply disable, which then makes it a a 404. We then redirect this page using a 301 redirect to a new relevant page. The reason for redirecting these pages is because the old pages are still being indexed in Google. I understand 404 pages will eventually drop out of Google's index, but was wondering if we were somehow preventing them dropping out of the index by redirecting the URL's, causing the 404 pages to be added to the sitemap. My questions are: 1. Could we simply delete the entire unwanted page, so that it returns a 404 and drops out of Google's index altogether? 2. Because the 404 pages are in the sitemap, does this mean they will continue to be indexed by Google?

              Intermediate & Advanced SEO | Apr 29, 2016, 3:41 AM | andyheath
              0
            • Jonathan.Smith

              Should I include URLs that are 301'd or only include 200 status URLs in my sitemap.xml?

              I'm not sure if I should be including old URLs (content) that are being redirected (301) to new URLs (content) in my sitemap.xml. Does anyone know if it is best to include or leave out 301ed URLs in a xml sitemap?

              Intermediate & Advanced SEO | Feb 10, 2016, 11:17 PM | Jonathan.Smith
              0
            • iamgreenminded

              Trailing Slashes for Magento CMS pages - 2 URLS - Duplicate content

              Hello, Can anyone help me find a solution to Fixing and Creating Magento CMS pages to only use one URL  and not two URLS? www.domain.com/testpage www.domain.com/testpage/ I found a previous article that applies to my issue, which is using htaccess to redirect request for pages in magento 301 redirect to slash URL from the non-slash URL.  I dont understand the syntax fully in htaccess , but I used this code below. This code below fixed the CMS page redirection but caused issues on other pages, like all my categories and products with this error: "This webpage has a redirect loop ERR_TOO_MANY_REDIRECTS" Assuming you're running at domain root.  Change to working directory if needed. RewriteBase / # www check If you're running in a subdirectory, then you'll need to add that in to the redirected url (http://www.mydomain.com/subdirectory/$1 RewriteCond %{HTTP_HOST} !^www. [NC]
              RewriteRule ^(.*)$ http://www.mydomain.com/$1 [R=301,L] Trailing slash check Don't fix direct file links RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_URI} !(.)/$
              RewriteRule ^(.)$ $1/ [L,R=301] Finally, forward everything to your front-controller (index.php) RewriteCond %{REQUEST_FILENAME} !-f
              RewriteCond %{REQUEST_FILENAME} !-d
              RewriteRule .* index.php [QSA,L]

              Intermediate & Advanced SEO | Oct 6, 2015, 1:25 AM | iamgreenminded
              0
            • Jay328

              Weird 404 URL Problem - domain name being placed at end of urls

              Hey there. For some reason when doing crawl tests I'm finding pages with the domain name being tacked on the end and causing 404 errors. 
              For example:  http://domainname.com/page-name/http://domainname.com This is happening to all pages, posts and even category type 1. Site is in Wordpress
              2. Using Yoast SEO plugin Any suggestions? Thanks!

              Intermediate & Advanced SEO | Mar 11, 2015, 6:56 PM | Jay328
              0
            • Visually

              Are there any negative effects to using a 301 redirect from a page to another internal page?

              For example, from http://www.dog.com/toys to http://www.dog.com/chew-toys. In my situation, the main purpose of the 301 redirect is to replace the page with a new internal page that has a better optimized URL. This will be executed across multiple pages (about 20). None of these pages hold any search rankings but do carry a decent amount of page authority.

              Intermediate & Advanced SEO | Feb 6, 2012, 11:04 AM | Visually
              0
            • digisavvy

              There's a website I'm working with that has a .php extension. All the pages do. What's the best practice to remove the .php extension across all pages?

              Client wishes to drop the .php extension on all their pages (they've got around 2k pages). I assured them that wasn't necessary. However, in the event that I do end up doing this what's the best practices way (and easiest way) to do this? This is also a WordPress site. Thanks.

              Intermediate & Advanced SEO | Oct 27, 2011, 4:44 PM | digisavvy
              0

            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.