Hello, we apologize for the issue you are facing with permalink changes in WooCommerce and Rank Math on your e-commerce website.
To optimize your WooCommerce product URLs and make changes to the permalink structure, you can follow these steps:
-
Remove Category Base: By default, WooCommerce adds /product-category/
before the actual category in the permalink. You can remove this base by enabling the option in Rank Math. This will make your URLs cleaner and easier to read. Here is a screenshot showing where to find this option:
-
Remove Parent Slugs: If you want to remove the parent category slug from your product page permalinks, you can enable the “Remove parent slugs” option in Rank Math. This will help in simplifying your URLs. Here is a screenshot illustrating this option:
-
Edit .htaccess: If you need to edit the .htaccess file for any specific redirects or configurations, you can do so within Rank Math in the Advanced Mode. Here is a screenshot showing where to access this feature:
If you encounter any issues or need further assistance with permalink changes in WooCommerce and Rank Math, feel free to reach out to our dedicated support team here. They are available 24/7 to assist you.
We appreciate your concern and thank you for reaching out to us for help with optimizing your e-commerce website’s permalinks. If you have any more questions or need additional support, please let us know!
Sources:
WordPress Permalink Structure & Changing Individual URLs » Rank Math
Rank Math’s Advanced Mode – Available Module, Options & More
How to Optimize a Category Page » Rank Math
How to Disable Custom Product Redirection in Rank Math » Rank Math
Hello,
Thank you for contacting us and bringing your concern to our attention.
Please note that the Auto post redirect option from Rank Math only applies when you’re changing the slug of your post types, not for the permalink structure or the actual base.
When changing the permalink structure, WordPress should handle the automatic redirections from the old permalink structure to the new one.
If somehow, WordPress fails to create a redirection for it, you will need to create a 301 regex redirect for the posts since their original URL has changed.
And here’s a guide you can follow to create regex redirect in Rank Math:
https://rankmath.com/kb/how-to-use-regex-redirects/
Hope that helps and please don’t hesitate to let us know if you have any other questions.
Â
Thank you.
Hello,
It is quite difficult to writhe regex rule. Would you think a new feature of RankMath can solve that ?
Thanks
Hello,
Rank Math doesn’t have the feature to set a global redirection if the permalink of the site is changed as we let WordPress do this type of redirection.
We don’t have any plans on adding such a feature but if this is something we can add in the future, we will surely do.
For now, if WordPress didn’t create any redirections after the permalink change, you’ll have to manually create the redirections as suggested by my colleague.
Looking forward to helping you.
Hello,
Since we did not hear back from you for 15 days, we are assuming that you found the solution. We are closing this support ticket.
If you still need assistance or any other help, please feel free to open a new support ticket, and we will be more than happy to assist.
Thank you.