Title: Exclude specific post from Recent Post widget
Last modified: August 20, 2016

---

# Exclude specific post from Recent Post widget

 *  [ganghiss](https://wordpress.org/support/users/ganghiss/)
 * (@ganghiss)
 * [13 years, 9 months ago](https://wordpress.org/support/topic/exclude-specific-post-from-recent-post-widget/)
 * I’m trying to remove a specific post, using post ID, from displaying in the default
   Recent Posts widget. Is there an exclude instance or agument to use? Also, not
   sure I’m calling the_widget and wp_widget_recent_posts correctly. Below is my
   screwy attempt in functions.php.
 *     ```
       function custom_recent_post_exclude($data) {
       	$data = array(
       	'widget' => wp_widget_recent_posts,
       	'instance' => 'exclude=45'
       	);
       	return $data;
       }
       add_filter( 'the_widget', 'custom_recent_post_exclude', 999 );
       ```
   

The topic ‘Exclude specific post from Recent Post widget’ is closed to new replies.

## Tags

 * ["recent post"](https://wordpress.org/support/topic-tag/recent-post/)
 * [exclude](https://wordpress.org/support/topic-tag/exclude/)
 * [widget](https://wordpress.org/support/topic-tag/widget/)

 * In: [Hacks](https://wordpress.org/support/forum/plugins-and-hacks/hacks/)
 * 0 replies
 * 1 participant
 * Last reply from: [ganghiss](https://wordpress.org/support/users/ganghiss/)
 * Last activity: [13 years, 9 months ago](https://wordpress.org/support/topic/exclude-specific-post-from-recent-post-widget/)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
