How to remove post from news feed wordpress

There are a few ways to remove a post from the news feed in WordPress, depending on the theme and plugins you're using. Here are a few methods:

Method 1: Using the WordPress Admin Panel

  1. Log in to your WordPress admin panel.
  2. Go to the "Posts" menu and select "All Posts".
  3. Find the post you want to remove from the news feed and hover over it.
  4. Click the "Quick Edit" button.
  5. In the "Visibility" section, select "Private" or "Draft" to remove the post from the news feed.
  6. Click "Update" to save the changes.

Method 2: Using a Plugin

If you're using a plugin like Yoast SEO or All in One SEO Pack, you can use their built-in features to remove a post from the news feed.

  1. Install and activate the plugin.
  2. Go to the plugin's settings page (e.g. Yoast SEO > Settings > News Feed).
  3. Find the post you want to remove from the news feed and toggle the switch to "Off" or "No" to remove it from the feed.

Method 3: Using a Theme-Specific Solution

Some themes, like Genesis or Thesis, have built-in features to remove posts from the news feed. Check your theme's documentation or settings page to see if this option is available.

Method 4: Using a Custom Code

If none of the above methods work, you can try using custom code to remove the post from the news feed. You'll need to add the following code to your theme's functions.php file:

function remove_post_from_news_feed($post_id) {
    // Get the post object
    $post = get_post($post_id);

    // Check if the post is in the news feed
    if (in_array($post_id, get_option('news_feed_posts'))) {
        // Remove the post from the news feed
        remove_post_meta($post_id, '_news_feed_post');
    }
}
add_action('save_post', 'remove_post_from_news_feed');

This code checks if the post is in the news feed and removes it if it is. You'll need to replace $post_id with the actual ID of the post you want to remove.

I hope these methods help you remove the post from your news feed in WordPress!