How To Display Related Posts by the Same Author In WordPress


With a blog that has multiple authors, you may want to display posts that are related to the current post but written by the same author. In this article, we will show you how to display related posts by the same author in WordPress.


While WordPress supports various options for displaying related posts on your website, posts will be selected from all authors contributing to your content. If you wish to filter the selection to only include posts by the same author, you can do so using the Similar Posts plugin.

The plugin is one of many “related posts” plugins available for WordPress, however, it includes a wide assortment of options for controlling the display, layout, and selection of posts.

To get started, log into your WordPress administration dashboard, then head for Plugins > Add New. Search for “Similar Posts”, then install and activate the plugin.


Once activated, navigate to Settings > Similar Posts to configure the plugin’s settings.


Tabs across the top of the Settings page allow you to customize the selection, formatting, and display of related posts. At the bottom of the General tab, click the dropdown menu next to Match the current author’s posts and select Yes.


Next, you need to switch to the ‘Placement’ tab and activate the ‘Output after post’ option. You can also edit the output template by editing the text in the ‘Parameters’ box.


Don’t forget to click on the ‘Save Settings’ button to store your changes.

You can now visit any single post on your website, and you’ll see related posts by the same author after the post content.

This method requires you to add code to your WordPress theme files. This code snippet will allow you to display related posts by the same author. To do this we need to add some code into both the functions.php page and the single.php page.


First, add the following to your functions.php page.

function get_related_author_posts() {

    global $authordata, $post;

    $authors_posts = get_posts( array( ‘author’ => $authordata->ID, ‘post__not_in’ => array( $post->ID ), ‘posts_per_page’ => 10 ) );

    $output = ‘<ul>’;

    foreach ( $authors_posts as $authors_post ) {

        $output .= ‘<li><a href=”‘ . get_permalink( $authors_post->ID ) . ‘”>’ . apply_filters( ‘the_title’, $authors_post->post_title, $authors_post->ID ) . ‘</a></li>’;


    $output .= ‘</ul>’;

    return $output;


This will get posts by the current author where the post ID is not the current post and gets a maximum of 10 results.


Now we have the function in the functions.php file we can use this inside the single.php file. Place a call to this function where you want this list appears.

      <?php echo get_related_athor_posts(); ?>

I hope this article helped you learn how to easily display related posts by the same author in WordPress. If so, I would love to hear about it in the comments below!

K2 Plugins has developed K2 blocks which is a WordPress plugin You can contact us for custom plugin development at our Official site

25 thoughts on “How To Display Related Posts by the Same Author In WordPress”

  1. Asking questions are really nice thing if you are not
    understanding something totally, however this piece of writing provides fastidious understanding

  2. I really love your blog.. Very nice colors
    & theme. Did you develop this site yourself? Please reply back as I’m hoping to create
    my very own site and would like to learn where you got this from or just what the theme is called.


  3. Your article gave me a lot of inspiration, I hope you can explain your point of view in more detail, because I have some doubts, thank you.

  4. Howdy! Quick question that’s completely off topic.
    Do you know how to make your site mobile friendly? My web site looks weird when browsing from my iphone.
    I’m trying to find a theme or plugin that might be able to correct this issue.
    If you have any recommendations, please share. With thanks!

  5. Hey there! I just wanted to ask if you ever have any trouble with hackers?
    My last blog (wordpress) was hacked and I ended up losing a few
    months of hard work due to no data backup. Do you have any methods to stop hackers?

Leave a Comment

Your email address will not be published. Required fields are marked *