How To Find Your WordPress Page And Post IDs

Learn how to easily find a WordPress post or page ID and why knowing how to locate your post and page IDs can be useful …

How To Find Your WordPress Page And Post IDsEver wondered how to exclude certain posts and pages from appearing in areas of your site like your sitemap?

One of the easiest ways to do this is to filter your pages or posts by their unique ID.

Your WordPress Post Or Page ID is a unique number that WordPress assigns automatically to every post or page created on your site.

Knowing your page or post ID is quite useful if for example, you want to exclude pages from displaying in your sitemap, or if you want only selected pages to display in the sidebar section of your website or blog.

In this step-by-step tutorial, you will learn how to locate the unique ID of WordPress pages and posts.

Finding WordPress Post And Page IDs: Tutorial

To find your page or post ID, log into your site and, depending on which ID you are trying to locate, either go to the Pages section (if you want the ID of a particular page) or the Posts section (if you need a particular post ID) …

WP Dashboard - WP Pages Menu - All Pages

(WP Dashboard – Pages Menu – All Pages)

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

Hover over the post title to view Page or Post ID

(Hover over the title to display Page or Post ID)

The “post or page ID” value is displayed in the status bar of your web browser. In the example below, the ID is 5575

Page ID displayed in your web browser

(Page ID)

Write down the ID of the post or page.

Practical Uses For Page IDs/Post IDs

Here are a few practical ways to use WordPress post and page IDs:

Excluding Pages And Posts From Showing In Your Site Map

Suppose we need to prevent a page whose ID is “26” from displaying to visitors on a site map.

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

Preventing pages or posts from showing in a site map

(Preventing posts or pages from showing in a site map)

Preventing Posts Or Pages From Appearing In Your WordPress Sidebar

Another useful application for unique page IDs is to prevent them from displaying in your WordPress sidebar.

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

Excluding pages and posts from displaying in your WordPress sidebar

(Exclude pages or posts from displaying in the WordPress sidebar)

Excluding Posts And Pages From Showing In Your XML Sitemap

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

Preventing posts or pages from showing in an XML sitemap|sidebar

(Exclude posts or pages from showing in an XML sitemap|sidebar)

Plugins – Page/Post IDs

If you would like to regularly access your page or post IDs, then here are a few FREE WordPress plugins that you may find useful:

Reveal IDs

Reveal IDs

(Reveal IDs – WordPress Plugin)

This plugin displays the IDs for posts, pages, categories, links, users, media, 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

(ID Column)

To access the plugin settings go to Settings > Reveal IDs

Settings - Reveal IDs

(WP Dashboard – Settings – Reveal IDs)

To learn more about this plugin, go here: 

99 Robots Show IDs

WordPress Plugin - 99 Robots Show IDs

(99 Robots Show IDs – WordPress Plugin)

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

Download the plugin here:

ID ARRAYS

ID Arrays

(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 Post/Page IDs to your clipboard.

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

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

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

To learn more about this plugin, go here:

Congratulations! Now you know how to find WordPress page and post IDs.

How To Find Your WordPress Page And Post IDs

***

"This is AMAZING! I had learnt about how to use WordPress previously, but this covers absolutely everything and more!! Incredible value! Thank you!" - Monique, Warrior Forum