Home Codingmagento Redirect Magento category to a URL

Redirect Magento category to a URL

by Ben

Do you have a category menu that you want to redirect to a URL instead?
Did you install aheadworks blog extension and wants to redirect a category to the blog? e.g. www.domainname.com/blog 

Below are the steps to get these done. You may refer to www.lingeriesg.com for example.

  1. In magento, click on Catalog -> Manage Categories
  2. Click on the root category that you wants to create and click on ‘Add Subcategory’ button
  3. Enter the name of the catagory. e.g. Blog and mark Is Active = Yes
  4. Once created, take note of the ID that is assigned to this category

    2

  5. Click on Catalog -> URL Rewrite Management
  6. Find and click on the entry of the category which you have just created. In my example below, it is id = 11

    3

  7. Set Redirect = permanent (301) and save

    4

  8. Go back to URL Rewrite Management
  9. Create a new entry. Create URL Rewrite = Custom
  10. Type in ID path = any name. e.g. myblog

    5

  11. Request Path = the category ID  which you have just copied
  12. Target Path = the path you want to redirect. In my case, i want to redirect to /blog. Thus, my target path is ‘blog’
  13. Redirect = Permanent
  14. Save this custom URL rewrite entry and clear your index by going to System -> Index Management -> Select All and click submit (Actions = Reindex Data)

Basically, what we have done so far is to mark category URL rewrite as permanent and then create a new URL rewrite that redirect the system(raw) URL to the one you intended to.

At the time of writing, I am using Magento community version 1.7.0.2

You may also like

5 comments

raj May 3, 2014 - 6:23 pm

thanks

Reply
Andy August 25, 2014 - 10:01 pm

This works in 1.9 as well 🙂

Reply
mohit March 18, 2015 - 2:19 pm

very nice.. simple

Reply
Gusti May 5, 2015 - 11:53 pm

Very good explanation, very usefull, thanks! Used in magento community 1.9.0.1.

Reply
Muhammad Saeed Khan May 5, 2016 - 2:32 pm

What about making the category name active? In current scenario, the category is not marked as selected in top Navigation Menu as it for other simple categories.

Thanks

Reply

Leave a Comment