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 IDsDo you need to know how to exclude certain pages and posts from displaying 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 assigned by WordPress to every post or page created on your site.

Knowing how to locate a page or post ID is really useful if for example, you want to prevent pages from showing in your sitemap, or if you want only certain pages to show in your WordPress sidebar.

In this step-by-step tutorial, you are going to learn how to locate WordPress post and page IDs.

How To Find The Post Or Page ID In A WP Website: Step-By-Step Tutorial

To locate the unique ID of any page or post, log into your site and either go to the Pages screen (to see IDs of pages) or the Posts section (if you want post IDs) …

WP Dashboard - WordPress Pages Menu

(WP Dashboard – All Pages)

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

Hover over the post title to view Post ID

(Hover over the title to see Post ID)

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

Page ID

(Page ID)

Record the ID of the post or page.

Uses For Page ID/Post ID

Here are some examples of using WordPress post or page IDs:

Prevent Posts Or Pages From Displaying In Your 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.

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

Prevent posts or pages from displaying in a site map

(Prevent pages and posts from displaying in your site map)

Excluding Pages Or Posts From Showing In The Sidebar

Another practical use for page IDs is to exclude them from displaying in your WordPress sidebar.

Just enter all of the Page IDs for the pages you want to exclude separated by commas into the Exclude field of the WordPress Pages widget, and click the Save button …

Prevent pages or posts from appearing in the WordPress sidebar

(Excluding posts or pages from appearing in your WordPress sidebar)

Prevent Pages And Posts From Showing In A Sitemap

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

Prevent pages and posts from showing in your XML sitemap|sidebar

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

WP Plugins – Page/Post IDs

If you want to know the IDs of your posts or pages on a regular basis, then here are some WordPress plugins you may find useful:

Reveal IDs

Reveal IDs - WordPress Plugin

(Reveal IDs – WordPress Plugin)

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

Posts Area - ID Column

(Posts Screen – ID Column)

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

Settings Menu - Reveal IDs

(Settings Menu – 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 another useful plugin that lets users view their posts, pages, media, links, users, categories and tags in the Pages and Posts admin tables. It’s also a super lightweight plugin that supports custom post types  and taxonomies.

Download the plugin here:

ID ARRAYS

ID Arrays Plugin

(ID Arrays – WordPress Plugin)

ID Arrays not only displays a column of IDs in your Table of Pages/Posts, it also provides a 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 allows you to 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 with many IDs required and the process of finding IDs one by one would be time-consuming.

To download this plugin, go here:

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

How To Find Your WordPress Page And Post IDs

***

"I was absolutely amazed at the scope and breadth of these tutorials! The most in-depth training I have ever received on any subject!" - Myke O'Neill, DailyGreenPost.com

Recommended Video Courses For WordPress Users

How To Use FTPHow To Use FTP

This video course shows you how to use FTP (File Transfer Protocol) to transfer and upload files between your hard drive and your server using a free FTP program called Filezilla.

More info: How To Use FTP

Recommended Video Courses For WordPress Users

How To Use Amazon S3How To Use Amazon S3

Learn how to set up and use Amazon S3 to upload, store, manage, and protect your site’s images, large media files, downloadable files, stream videos and more.

More info: How To Use Amazon S3

Recommended Video Courses For WordPress Users

How To Use cPanelHow To Use cPanel

cPanel is a powerful and simple-to-use web hosting management software application that gives website owners the ability to quickly and easily manage their servers and websites using a simple and intuitive dashboard.

This video course will teach you how to use the main features of cPanel to manage your web hosting.

More info: How To Use cPanel

Recommended Video Courses For WordPress Users

How To Set Up WordPress On LocalhostHow To Set Up WordPress On Localhost

Learn how to install, set up, and locally host a fully functioning WordPress site on your computer.

More info: How To Set Up WordPress On Localhost

Recommended Video Courses For WordPress Users

How To Optimize WordPressHow To Optimize WordPress

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

More info: How To Optimize WordPress

Author: Martin Aranovitch

Martin Aranovitch is the owner of WPCompendium.org and the author of The WordPress User Manual. WPCompendium.org provides hundreds of FREE tutorials that show you how to use WordPress to grow your business online with no coding skills required! Get our FREE "101+ WordPress Tips, Tricks & Hacks For Non-Techies" e-course with loads of useful WordPress tips!

Originally published as How To Find Your WordPress Page And Post IDs.