When installing a new theme or configuring a PHP script for your WordPress, you might need to populate some entries with a WordPress Category ID. Even though an advanced WordPress user can find a Category ID in seconds, if you are a beginner you might be at lost. Follow the below step by step procedure to find a WordPress Category ID in seconds.
Procedure to find WordPress Category ID
Login to your WordPress dashboard (http://[yoursite]/wp-admin).
Navigate to the Posts > Categories node from the WordPress Dashboard left hand side menu.
Move the mouse over the name of the WordPress Category you would like to know the ID of (without clicking) and notice the URL that shows up at the bottom left corner of the browser, which is highlighted in the below screenshot.
The format of WordPress Category ID URL will always be the same, in this case:
On the browser link look for the tag_ID=X, where X is always the WordPress category ID (highlighted in red in the above URL example). So in the above example URL, the category ID is 4.
Copying the WordPress Category ID URL
If for some reason you are unable to see such URL, simply move the mouse cursor over the WordPress Category name and copy the link by right clicking it and selecting ‘Copy Link Location’ or ‘Copy Link Address’ from the right click menu and paste the URL to a text editor such as notepad.
If you want to learn more about WordPress security, read our definitive guide on WordPress security & hardening.