Posted in WordPress by
Anthony Hortin

If you run a WordPress website, then you’re probably familiar with the Yoast SEO plugin by Joost de Valk. Not only is it a fantastic plugin for helping improve the SEO of your site, it also has some great extra features such as Page Analysis,Β  XML Sitemaps and Social Integration. Whenever you hear people talk about which SEO plugin to use on their site, nine times out of ten people will simply recommend Yoast SEO.

Over the years, they’ve introduced various adverts in the settings pages and typically I don’t have and issue with this sort of thing, especially when it’s a free plugin. Recently though, they’ve introduce a new notification after the plugin is updated.

Yoast SEO update nag

The message indicates that it will tell you what’s been updated in the latest version, when in fact, it simply takes you to a full ‘About’ page with a list of features for that major version release (in this case, for version 2.3).

Yoast_update_page_croppedNow, as I said above, normally I don’t have too much of an issue with notifications like this, especially when they’re dismissable. However, there’s a few annoying features with this particular notification. First up, it doesn’t simply disappear when the page is refreshed, like a lot of these types of notifications. Secondly, and more annoyingly, is that it will display for every single Administrator on your site. So, no matter who updates the plugin, every Admin user will get the notification.

When you’re maintaining sites for your clients, this becomes a real annoyance as you don’t necessarily want those users to be inundated with plugin update notifications when you’re handling the updates for them. Also, as it is at the moment, the plugin will actually show multiple notifications on the screen at once, if they’re not cleared each time. This latter issue is one that I’ve raised with the developers and will hopefully get addressed soon. Unfortunately though, they aren’t interested in stopping the notification from displaying to all Admin users.

Since I’m not wanting to login as every Admin user on every site I’m maintaining, just to clear the notification, I’ve written a short bit of code that will automatically clear it for you when the plugin is updated, or activated. Pretty sweet eh!

Simply add the following to your functions.php file and you should be set! No more Yoast nag!

Let me know in the comments if you’ve found this helpful or if you know of any other plugins that display annoying nags.

20 responses on “Remove Nag after Yoast SEO Plugin Updates

  1. Justin

    This is super-handy and a great idea. I love that you’re still requiring that users “view” the update, but after that, the neg should be removed.
    However, I’m not sure it works on a multisite install using Yoast SEO network activated. I added the following to your ryn_remove_yoast_nag() function to make sure we’re catching super-admins that might have a role less than administrator for a specific network site (for whatever reason).

    private function ryn_remove_yoast_nag() {
    $pluginData = get_plugin_data( WPSEO_FILE, false );
    $pluginVersion = $pluginData['Version'];
    $adminUsers = get_users( array( 'role' => 'administrator' ) );
    $superAdminUsers = get_super_admins(); 
    $allAdmins = array_merge($adminUsers, $superAdminUsers);
    // Since the nag displays for all admin users, let's clear it for all admin users
    foreach ( $allAdmins as $user ) {
        if ( get_user_meta( $user->ID, 'wpseo_seen_about_version', true ) !== $pluginVersion ) {
          update_user_meta( $user->ID, 'wpseo_seen_about_version', $pluginVersion );
        }
      }
    }
  2. Joe Fletcher

    You read my mind – thanks for the code, will try it out. Besides the annoyances you listed, it’s also annoying simply b/c the plugin updates so frequently that I’m constantly clicking that notification away practically every time I’m in one of my client’s sites. I personally don’t want or need to see that notification. I’m happy to visit the changelog if and when I’m in there doing SEO work.

    1. Anthony Hortin Post author

      Yeah, I know what you mean. They’ve been releasing a lot of updates lately. Mostly to fix their own bugs too! There was 3 releases in 3 consecutive days the other week. I hope this code helps you out.

    1. Anthony Hortin Post author

      Hi Robin. Just to let you know, if the Yoast notification is already showing on your site, it wont get removed as soon as you add this bit of code. It will only remove the notification when the plugin is updated through WordPress or the plugin is activated.

  3. Justin

    Anthony,

    Any chance you could update your (awesome) function(s) to also remove the “Don’t miss your crawl errors: connect with Google Search Console here” persistent nag?

    Judging by the comments of late on the WordPress repository, I’m not the only one that’s tired of persistent Yoast Nags.

    1. Anthony Hortin Post author

      Hi Justin. Yeah, I noticed they’ve now added in a brand new one as well. So annoying! If I get some time over the next week I’ll try and update the code to get rid of this new one as well. Thanks for the reminder.

      1. Joe Fletcher

        I just had THREE Yoast nags at the same time! The 2 above and 1 more (I forget what it was). I was going to screenshot it and “nag” Yoast about it on Twitter, but was in a hurry, and also would have felt bad complaining about free software.

        1. Anthony Hortin Post author

          Hey Joe,
          They’ve supposedly fixed that issue in one of their recent versions as I bought that up with their developers over on Github as I was seeing multiple notifications as well. It’d be worth saying something to them. If enough people tell them how annoying these are, maybe they’ll rethink how they display them. I wouldn’t have too much of an issue if it only displayed the notification to the person who updated, but I find it extremely annoying that it shows to ever Admin user. Thanks for your comment πŸ™‚

  4. Mitch

    Hey Anthony, Mitch from slack here πŸ˜‰

    I stumbled across your post, exactly looking for this info and your on the first page πŸ˜€ hooray for SEO… lol

    Anyway, ive been getting the real shits with Yoast lately their plugin has gone from good to just plain annoying not only is there the Search Console Nag but also the nag of the plugin has been updated.. blah blah click here to view.. blah blah… seriously this needs to be an option to turn on or off…. other plugins are the same iThemes Security is bad also, not put both of them together and you get at least 3x nags on the top of the screen that almost make your site look spammy… come on mannnnn serioulsyyyyyy.

    I wonder if its time to jump ship and use something like Seo AIO plugin…. (not sure if its as bad)

    Whilst i like the idea of what you gave as a temp fix, i dont want to keep updating it ay…….. 😐

    1. Anthony Hortin Post author

      Hey Mitch!

      Glad you found my post. Yeah, I know how you feel. Yoast have been putting out so many updates lately, and most of them to fix their own bugs that they’ve introduced. And their nags are getting more and more annoying. It’s frustrating that you have to include code like this to get around annoying features and I’ve raised the issue with the developers, about it displaying for every admin user, but unfortunately, they have no intention of removing or changing it. I guess until more and more people complain to them, they’re here to stay *sigh*

      1. Mitch

        Here is a thought…. make a plugin that goes about and removed stupid nags from various popular plugins :DDDDD will reach top 10 installs in a few months πŸ˜‰

  5. Vincent

    Hi Anthony,

    Thanks for this and I am looking forward to implementing it ASAP.

    One get the feeling that the nags are there deliberately to show webmasters clients that the SEO is run via Yoast Plugin and hopefully have your clients coming to you and wanting to know more or at the very least clicking through to make the purchase from Yoast. It appears that many parts of the plugin are maximised for this. I noted a couple of months ago that there is now a live link on the XML sitemap going back to Yoast.

    The plugin is excellent and provides some very neat features. I don’t blame the developer for wanting to push sales. However, I feel it is going out of the WordPress ideal when it starts to become pushy and overtly smacks its brand continuously on sites you build.

    1. Anthony Hortin Post author

      Yeah, you’re right. They’re obviously trying to get as much exposure as possible whilst still staying within the Plugin Directory guidelines. I think there’s a fine line though between providing a useful notification and just be annoying and pushy, as you you said.
      I hope you find my code useful. Thanks for leaving a comment.

    1. Anthony Hortin Post author

      Thanks Brent. Yep, I did notice that plugin in the repo. One thing I didn’t really like about it though was that it simply injects some css with display: none; to get rid of the notification messages, whereas my code above updates the user meta key to get rid of the message completely.

    1. Anthony Hortin Post author

      Yeah, they don’t seem too interested in remove their nags. I’ve tried raising issues on Github as well but they refuse to do anything about them. Glad you found this useful. Thanks for leaving a comment.