WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I would like to run several actions on a website once WP core or any of the plugins have been updated using the built-in update process. Is there a way to do it?

I would prefer if I could run commands on 3 different cases:

  1. WP core update is finished
  2. A single plugin update has been finished
  3. A bulk update for plugins has been finished (so that I run the command only

after all of them have been finished)

share|improve this question
Any progress on this question? Ever? – kaiser Aug 28 '13 at 7:26
Sorry, I haven't had a chance to try out your solution. – ragulka Aug 28 '13 at 12:50
up vote 4 down vote accepted


The hooks you're searching for are




The later takes three arguments. Example:

function upgrader_post_install_cb( $true, $hook_extra, $result )

and should be used for: Move & activate the plugin, echo the update message.

Moving plugins

Moving works like this:


Then use activate_plugin( 'path/file' ); after moving.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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