WordPress action hook · part of WordPress core

post_updated

A WordPress core action that 17 plugins also fire themselves, running on 23K+ sites between them.

“This action is documented in wp-includes/post.php”

How to use post_updated

It's an action: your callback runs at that point and receives 3 arguments. Nothing needs to be returned. Add this to your theme's functions.php or a small custom plugin:

functions.php
add_action( 'post_updated', function( $post_id, $post, $post2 ) {
	// Your code runs here.
}, 10, 3 );

Argument names come from Royal MCP's source. Other plugins may pass different values: check the call in the plugin you're targeting below.

This hook is fired by WordPress core too. Official reference on developer.wordpress.org →

17 plugins that fire post_updated

Sorted by active installs. Each entry shows where the plugin calls the hook and what it passes.

  1. Royal MCP icon Royal MCP10,000+ installs do_action( 'post_updated', $post_id, $post, $post ) includes/MCP/Support/Post_Write_Hooks.php:56
  2. 404 Solution: Redirection and Page Suggestions icon 404 Solution: Redirection and Page Suggestions10,000+ installs do_action( 'post_updated', (int)$before->ID, $after, $before ) includes/services/WordPressPostMutationNotifications.php:103
  3. Seamless Donations is Sunset icon Seamless Donations is Sunset2,000+ installs do_action( 'post_updated', $post_ID, $post_after, $post_before ) inc/utilities.php:1763
  4. Greek Multi Tool icon Greek Multi Tool1,000+ installs do_action( 'post_updated', $post_id, $after, $before ) includes/class-grmlt-converter.php:828
  5. MEGA AI icon MEGA AI200+ installs do_action( 'post_updated', $post_id, $post_after, $post_before ) mega.php:8892
  6. ContentGecko Connector icon ContentGecko Connector60+ installs do_action( 'post_updated', $post_id, $post, $post ) includes/services/class-cg-post-service.php:829
  7. Post ID Optimizer icon Post ID Optimizer10+ installs do_action( 'post_updated', $post_ID, $post_after, $post_before ) post-poidopt.php:3931
  8. Dynamic Functionalities icon Dynamic Functionalities10+ installs do_action( 'post_updated', $post_id, $after, $post ) includes/features/class-link-health-editor.php:238
  9. ProRank SEO icon ProRank SEO10+ installs do_action( 'post_updated', $id, $after, $before ) includes/Core/Content/PostContentWriter.php:76
  10. PerfLocale icon PerfLocaleFewer than 10 installs do_action( 'post_updated', $post_id, $after, $post ) src/Translation/PostSlugCheck.php:139
  11. Promo Revert icon Promo RevertFewer than 10 installs do_action( 'post_updated', $page_id, $after, $before ) includes/class-campaigns.php:856
  12. CatalogFAQ icon CatalogFAQFewer than 10 installs do_action( 'post_updated', $id, $updated, $post ) src/Core.php:407
  13. Zeopilot icon ZeopilotFewer than 10 installs do_action( 'post_updated', $id, $post, $before ) conditional-content.php:194
  14. MATUQO Media Importer icon MATUQO Media ImporterFewer than 10 installs do_action( 'post_updated', $id, $new, $old ) includes/import.php:238
  15. WingPilot icon WingPilotFewer than 10 installs do_action( 'post_updated', $post_id, $post, $post ) includes/class-cache-purger.php:64
  16. show.fm Podcast Player icon show.fm Podcast PlayerFewer than 10 installs do_action( 'post_updated', $post->ID, $updated, $post ) includes/class-migration-swap.php:163
  17. IPS Order Media Cleanup icon IPS Order Media CleanupFewer than 10 installs do_action( 'post_updated', $object_id, $post, $old ) includes/classes/Media/Recovery/ReferenceJournal.php:63

Need a customisation built on this hook?

Tell us what you want to change and which plugin it's for. We'll write it, test it and send it back as a small plugin.