How to Strategically Hide Posts from Your WordPress Blog Home Page
If you‘re one of the millions of people using WordPress to power your blog, you know that by default, your home page displays a list of your latest posts.
In fact, WordPress now powers over 40% of all websites, and many of those are blogs just like yours. A typical blog home page might show anywhere from 5-10 recent posts, giving readers a glimpse into the type and range of content you create.
But what if you want to showcase something other than your latest posts on the home page? Maybe you have a key piece of cornerstone content you always want to feature front and center. Or perhaps you have some older, evergreen posts that are more representative of your blog than your most recent ramblings.
That‘s where strategically hiding selected posts from your home page comes in handy. By curating which posts appear on that prime real estate, you can shape your readers‘ experience and make a strong first impression that aligns with your brand and content goals.
Why Hide Posts from Your Home Page?
Before we dive into the how-to, let‘s discuss the why. There are several potential benefits to hiding posts from your blog home page:
Better Reader Experience
When someone new lands on your blog home page, you have mere seconds to capture their attention and convince them to stick around. If your latest posts happen to be on a niche topic, or not your best work, they may not make the best first impression.
By hand-selecting which posts appear on the home page, you can ensure that readers see your strongest, most engaging content right off the bat. This increases the chances that they‘ll click through to read more and even subscribe.
Increased Visibility for Key Content
Maybe you have an epic, cornerstone piece of content that acts as the perfect introduction to your blog. Or perhaps you have a few key posts that you know resonate with your target audience and drive lots of engagement.
Normally, these posts would get pushed down the home page as you publish new content. But by hiding your other posts, you can keep these high-performing pieces front and center for maximum visibility and impact.
Seasonal Relevance
If you tend to publish seasonal content – like holiday gift guides or spring cleaning tips – those posts can quickly look outdated on your home page once the season passes. But you likely want to keep them published on your site so they can gain search engine authority and be ready to reshare when the season rolls around again.
Hiding seasonal posts from the home page after their timeliness has passed is an easy way to keep your blog looking fresh and current. You can always unhide them when the time is right.
Better for SEO?
This one is debatable. On one hand, your home page is often the most linked-to page on your site, so the posts shown there may get an SEO boost from that link equity. However, Google and other search engines are also pretty smart about finding and ranking individual posts on their own merits.
In general, strategically hiding a few posts from the home page is unlikely to help or hurt your SEO in a major way. The key is to not go overboard and hide the majority of your content. You still want your home page to provide a good overview of what your blog covers for both readers and search engines. Think of hiding posts as a scalpel, not a sledgehammer.
Now that we‘ve covered the why, let‘s get into the meat of how to actually hide blog posts from your home page. There are two main methods: manually with code, or with a WordPress plugin. We‘ll walk through both step-by-step.
How to Hide Posts from the Home Page Manually
If you‘re comfortable editing your WordPress theme files, you can hide posts with a bit of code. Don‘t worry – even if you‘re not a developer, this is still doable.
Step 1: Find Your Post IDs
The first thing you‘ll need are the unique ID numbers of the posts you want to hide. Here‘s how to find them:
- In your WordPress dashboard, go to Posts → All Posts
- Hover over the title of a post you want to hide
- Look in the URL that appears at the bottom of your browser window
- The post ID is the number that appears after
"post="
For example, if the URL looks like https://yoursite.com/wp-admin/post.php?post=123&action=edit, the post ID is 123.

Jot down the IDs of all the posts you want to hide from the home page. If you have a lot, you may want to use a plugin like Reveal IDs to display them directly in the Posts list for easy reference.
Step 2: Add the Code Snippet
Now that you have your post IDs, you‘ll add a snippet of code to your theme to hide those specific posts. Here‘s how:
- In your WordPress dashboard, go to Appearance → Theme Editor
- In the file list on the right, locate the
functions.phpfile and click to edit it - Scroll down to the very bottom of the file and paste this code block:
function hide_posts_from_home($query) {
if ($query->is_home() && $query->is_main_query()) {
$query->set(‘post__not_in‘, array(POST_ID_1, POST_ID_2));
}
}
add_action(‘pre_get_posts‘, ‘hide_posts_from_home‘);
-
Replace
POST_ID_1andPOST_ID_2with the actual ID numbers of the posts you want to hide, separated by commas. You can hide as many posts as you want – just add the IDs to the array separated by commas. -
Click the Update File button to save your changes
That‘s it! The posts with the IDs you specified will no longer appear on your blog home page. If you ever want to unhide them, simply remove the IDs from the code array.
A couple notes on this method:
- This code snippet goes in the
functions.phpfile of your currently active theme. If you‘re using a child theme, it should go in the child theme‘sfunctions.phpfile, not the parent. - The code as written will only hide posts from the blog home page, not other archive pages like categories or tags. If you want to hide them from other archives as well, remove the
is_home()part of the if statement. - This method works for both posts and pages, as long as you have the correct IDs
- If you‘re not comfortable editing theme files, don‘t worry – the plugin method described next is even easier
How to Hide Posts with a Plugin
If you‘d rather not mess with code, you can easily hide posts with the help of a WordPress plugin. There are a number of free plugins that add a simple checkbox to hide posts from the home page. Here are a few of the most popular ones:
-
WP Hide Post – This is a simple, lightweight plugin that adds a "Hide on frontpage" checkbox to the publish meta box. It‘s a good choice if you just want to hide posts from the home page and nothing else.
-
WordPress Hide Posts – This plugin adds a more robust interface for hiding posts, with options to hide from various archive pages, hide the post title, set expiration dates, and more. Good if you need more control than just the home page.
-
Zero Bounce Hide Posts – Another straightforward option that simply adds a "Hide Post" checkbox to the publish box. It also adds a handy column to the Posts list in the admin so you can easily see which posts are hidden.
All of these plugins work in essentially the same way:
- Install and activate the plugin of your choice
- Edit the post you want to hide
- In the publish meta box, check the box to hide the post
- Update the post to save the change

The checked post will now be hidden from your blog home page, but still accessible directly via its URL. Easy peasy!
One advantage of using a plugin is that you can quickly hide and unhide posts without having to edit any code. Simply uncheck the box and update the post to make it visible on the home page again.
The only potential downside is plugin bloat – if you‘re already using a lot of plugins, you may not want to add another one just for this purpose. But if you‘re comfortable with the code method, that‘s certainly the most lightweight option.
Alternative Approaches
In addition to hiding individual posts, there are a couple other ways you can curate what appears on your blog home page:
Switch to a Static Homepage
By default, WordPress shows your latest posts on the home page. But you can also set a static page as your home page and display the blog on a separate page. This gives you complete control over the home page content.
To set a static home page:
- Create a new page that will act as your home page
- Create another new page that will house your blog posts
- Go to Settings → Reading in your WordPress dashboard
- Under "Your homepage displays", select "A static page"
- Use the dropdowns to set your home page and posts page
- Save the changes
Now visitors to your home page will see the static page you set, with the blog displayed separately. This can be a good choice if you really want to craft a specific first impression, or if your site is more than just a blog.
Use Sticky Posts
WordPress has a built-in feature called "sticky posts" that allows you to keep selected posts at the top of your blog home page. Sticky posts are still in chronological order with the rest of your posts, but they‘ll always appear first.
To make a post sticky:
- Edit the post you want to make sticky
- In the publish meta box, check the box next to "Stick to the top of the blog"
- Update the post
You can have multiple sticky posts – they‘ll appear at the top of the home page in the order they were made sticky.
This can be a good alternative to hiding posts if you only have a handful that you want to feature. The sticky posts will be the first ones readers see, but your other recent posts will still be visible below.
Key Takeaways
Phew, that was a lot of information! Let‘s recap the key points:
- Hiding individual posts from your WordPress home page can improve the reader experience, highlight key content, maintain seasonal relevance, and potentially boost SEO
- You can hide posts manually with a code snippet in your theme‘s
functions.phpfile - WordPress plugins like WP Hide Post make it easy to hide posts without code
- Think strategically about which posts to hide – you still want your home page to give an overview of your content
- Hidden posts are still accessible via direct URL and have SEO value
- Alternatives to hiding posts include using a static home page or sticky posts
Whether you opt for the manual code method or a plugin, hiding posts from your blog home page is a simple way to curate a strong first impression for your readers. By putting your best content front and center, you increase the chances that new visitors will stick around to read more.
Just remember – with great power comes great responsibility. Don‘t go overboard and hide everything! Your home page should still give readers and search engines alike an enticing taste of what your blog is all about.
Happy hiding!
This post contains affiliate links. If you click through and make a purchase, I may receive a commission (at no additional cost to you). Thanks for your support!
