I've got a bunch of slugs that look something like this:



Fwiw, I think I did an import, then moved those to Trash, then did another import. Because I had Pages with an existing slug, the new Pages were given a "-2" suffix.

The question, however, is can I automatically rename all of these slugs and delete these suffixes? Either in pure SQL or via a Plugin.

1 Answer 1


First thing I would backup and restore the site on a local development environment. Then you can try use this tool on your local site: https://interconnectit.com/products/search-and-replace-for-wordpress-databases/ Make sure that when you rename you are giving them something unique otherwise you may get in trouble.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.