How to Add Recent Posts by Category in WordPress Sidebar

This method is recommended for users who want to display recent posts from specific categories in their WordPress sidebar.

Simply go to the Appearance » Widgets page and add the ‘Latest Posts’ block to your sidebar.

By default, the block will show your most recent posts. You edit the block settings and scroll to the ‘Sorting & Filtering’ section.

From here, you can choose the category that you want to display posts from.

Optionally, you can choose to show featured image, excerpt, author, and more.

Don’t forget to click on the Update button to publish your changes.

You can now visit your website to see your recent posts filtered by category.