Sometimes you need to know page or post id in a way to build your site. Especially in shortcode widget. There are several methods to find page or post id.
Get from URL
You can get page or post id from url information. Place your mouse over the page(post) whose id you would to get and you can see url. The number appearing after ‘post=’ is the result.
Get from plugin
By using plugins like Show IDs by 99 Robots, you can get a page or post id with ease.