adding posts to a page in wordpress

How To Add Featured Posts To A Page In WordPress

This post may contain partner links. This does not affect the price you pay.

This video will demonstrate how to feature a post within a page.

Featuring posts within a WordPress page is a great way to funnel your traffic towards your favorite posts. You can watch the video above, or follow the steps below for more information about inserting posts within a page.

One of the easiest ways to feature some posts within a page is by using the query loop block. Let’s look at how this done, step by step.

Steps To Adding A Post Within A Page

This tutorial assumes you have your page open, and you are ready to insert the posts within that page.

1. Insert Query Loop Block

Once you hit the plus button to insert a new block, you can search for the Query Loop block. This block is provided to the native Gutenberg Page Builder, and it truly is a game changer for blog writers.

search query loop block
Adding the Query Loop Block To A Page

In the past, you needed to develop a page in php, and use the query loop function in php to insert posts into your page. Now, you can use the Query Loop block.

2. Pick A Template For Post Appearance

Next, browse the available templates to give a starting point for how your posts will look within your page. You can customize the look of the posts, but a template will help you get started. Click the arrow in the bottom left to scroll through the templates, and find one that looks acceptable.

browse pattern for query loop
Choose a pattern for the layout of your posts. Scroll with the arrow in the bottom left.

This site prefers the two column layout with the featured image next to the title. See the WordPress Blogging Page for an example of this query loop layout.

3. Customize Post Layout

Use the List View to examine your query loop block. You will see post template, which controls the blocks that determine how each post is displayed. If you want to add post date, insert the post date block within the post template. If you want to remove the Post Excerpt, remove the Post Excerpt block.

customize post layout
Using the List View, add and remove post meta to determine how your post looks.

4. Customize Query Loop

The query loop settings on the right under block settings will determine which posts you display.

The first thing you need to do is uncheck the Inherit From Template Toggle within the block settings. Once you disable that, you can click Filter, and display posts by category or tag. To display three featured posts, you would give those posts the tag “Awesome Tag,” and then Filter the Query Loop by tag “Awesome Tag.”

filter posts by tag
Adding a tag to display a specific post within a page.

5. Adjust Number Of Posts Displayed

To adjust the number of posts displayed within the Query Loop, you need to look in the menu that appears near the cursor when you click the actual block. That setting is located in the little menu bar that pops up with you click the block.

adjust number of posts displayed
Notice in List View, the Query Loop block is selected. Now you can adjust the number of posts that appear in the filter icon that appears in the menu box options.

Last Thoughts

Using the Query Loop block is one of the easiest ways to insert posts into your pages. In this tutorial, we covered how to pick a template, and customize the layout so that your posts appear exactly how you want them to look. Lastly, to control the number of posts that are displayed, be sure to click the query loop block itself, and find that setting in the little menu bar settings that pop up when you click the block.