I have a weird problem.

I have a page that changed URL (because it's parent changed name).

Example Link https:www.mysite.com/my-services/service-1

is now: https:www.mysite.com/services/service-1

the canonical url however is still the original one: https:www.mysite.com/my-services/service-1

which is wrong. (it should be the new link)

This is what I tried:

  • I had the redirection plugin to handle the redirect, but have switched that one iff > does not solve the problem

  • I have switched of Yoast > doesn't help

  • I switched on Yoast again - and explicitely changed the canonical link in the Yoast SEO section of th page > that solves it.

However I don't want to manually have to change a canonical like this. Is there a better solution? Am I missing something? Can I regenerate canonical tags in batch? So many questions - is there someone with an answer?

Thanks a lot in advance, Ingrid

2 Answers 2


You need to reset your indexables. There are a couple of ways to do this - you can use a WP-CLI command (wp yoast index), or you can use the Yoast Test Helper plugin.

If you install the Yoast Test Helper Plugin, you can go to Tools > Yoast Test. In the "Yoast SEO" box with a bunch of buttons, use the "Reset Indexables tables & migrations" button to flush them. You can then uninstall the plugin, remove your manually-entered canonical URL, and the default (autogenerated) canonical URL will be fixed.

Theoretically, anytime you make a change such as changing a parent page URL, that should trigger Yoast to automatically update its indexables. So it may be worth opening a GitHub issue so they're aware this didn't happen as intended.

  • Hi @WebElaine - thanks so much for your answer, that seems to have solved it! I must say that the Yoast plugin has been pretty reliable, but lately it is getting more buggy. Quite annoying. Thanks again for your help! Commented Jun 9, 2020 at 19:02
  • WP CLI command didn't seem to work for me, but the Yoast Test Helper plugin did the job. Thanks!
    – daggerhart
    Commented Mar 27, 2023 at 16:46

I changed the status of the page from "published" to "draft" and then back to "published" and the canonical url was updated.

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.