WordPress For Non-Techies: Free WordPress Tutorials – WPCompendium.org

How To Find Your WordPress Page And Post IDs

Do you need to know how to prevent general access to certain pages or posts in areas of your website like your sitemap?

Often, the easiest way to do this is to filter your pages or posts by ID.

Your WordPress Page Or Post ID is a unique number assigned by WordPress to every post or page you create.

Knowing the post or page ID is quite useful if for example, you want to prevent pages from displaying in your sitemap, or if you want only certain pages to display in the sidebar.

In this tutorial, you will learn how to easily locate the ID of any WordPress post or page.

How To Find The ID Of A WordPress Page Or Post: Step-By-Step Tutorial

To locate your page or post ID, log into your site’s dashboard and, depending on which ID you are trying to locate, either go to the Pages screen (to see IDs of pages) or the Posts screen (to see IDs of posts) …

(WP Dashboard – WordPress Pages Menu – All Pages)

Select the page or post that you want to know the ID of and hover your mouse over the title …

(Hovering over the post title displays Page or Post ID)

The unique “ID” value is displayed in the status bar of your web browser. In the image below, the ID is 5575

(Page ID displayed in your web browser)

Write down the ID of the page or post.

Practical Uses For Post ID/Page ID

Here are a couple of practical ways to use page and post IDs:

Prevent Pages Or Posts From Displaying In A Site Map

In the example below, let’s say that you would like to prevent a page whose ID is “26” from displaying to visitors on a site map.

Site map plugins typically contain fields that let you specify the IDs of items you want to exclude (e.g. categories, pages, etc.) …

(Prevent posts or pages from appearing in a site map)

Excluding Posts Or Pages From Showing In Your WordPress Sidebar

Another useful application for unique page IDs is to exclude them from displaying in the sidebar section of your website.

To do this, just enter all of the Page IDs for the pages you want to exclude separated by a comma into the Exclude field of the Pages widget, then click the Save button …

(Prevent posts or pages from displaying in your WordPress sidebar)

Exclude Pages Or Posts From Showing In A Sitemap

You can also use post and page IDs to exclude posts or pages from your XML sitemap …

(Exclude pages or posts from displaying in the XML sitemap|sidebar)

Plugins – Page IDs

If you need to access your post or page IDs inside your admin area when you log in, then here are some WordPress plugins that you may find useful:

Reveal IDs

(Reveal IDs – WordPress Plugin)

This plugin displays IDs for posts, pages, links, categories, media, users, link categories, comments, custom post types, custom taxonomies and tags. It also adds a sortable column header to your Pages and Posts tables …

(ID Column)

You can access the plugin settings area by going to Settings > Reveal IDs

(Settings Menu – Reveal IDs)

Learn more about the plugin here: 

99 Robots Show IDs

(99 Robots Show IDs WP Plugin)

99 Robots Show IDs is another useful WordPress plugin that lets users see their pages, posts, links, media, categories, tags and users in the Pages and Posts admin tables. It’s also a very lightweight plugin that supports custom post types  and taxonomies.

Download the plugin here:


(ID Arrays WordPress Plugin)

ID Arrays not only displays a column of IDs in your Table of Posts/Pages, it also provides a very useful function that lets you copy a list of selected Page/Post IDs to your clipboard.

(ID Arrays lets you select and copy a list of Page/Post IDs to your clipboard)

This can be very useful if, for example, you are working with a long list of pages where many IDs are required and finding each ID would be time-consuming.

Download this plugin here:

Congratulations, now you know how to locate page and post IDs in WordPress.


"I am beyond impressed with what you have put together. I can tell that you put a ton of hard work into building what you have. You have the absolute best content on WordPress I have ever seen!" - Robert T. Jillie

Recommended Video Courses For WordPress Users

How To Back Up & Restore WordPress Sites

Learn how to safely and automatically backup your WordPress files and database and how to easily restore your WordPress site if something were to happen.

More info: How To Back Up & Restore WordPress Sites

Recommended Video Courses For WordPress Users

Build An e-Commerce Store With WordPress

Learn how to set up an e-commerce store on your WordPress site using e-commerce platforms like WooCommerce and Easy Digital Downloads.

More info: Build An e-Commerce Store With WordPress

Recommended Video Courses For WordPress Users

Using S2 Member

Learn how to set up and configure a WordPress membership site using the S2 Member free WordPress membership plugin.

More info: Using S2 Member

Recommended Video Courses For WordPress Users

How To Optimize WordPress

Learn how to optimize your WordPress site and improve your page loading speed.

More info: How To Optimize WordPress

Recommended Video Courses For WordPress Users

How To Set Up A Forum On WordPress

Learn how to set up a forum for your visitors, prospects, customers, members, or affiliates using WordPress.

More info: How To Set Up A Forum On WordPress