The Complete Guide to Displaying Related Posts in WordPress

Driving traffic to your website is an ongoing battle. But getting visitors to actually stay and read your content can be even more challenging.

According to HubSpot, the average website bounce rate is over 50%. That means more than half of visitors leave without browsing past the first page.

As a webmaster and WordPress expert with over 15 years of experience, I‘ve learned one of the most effective ways to engage visitors is showing related posts.

But what‘s the best approach to displaying related posts in WordPress?

In this comprehensive guide, we will cover:

  • The benefits of adding related posts
  • Comparison of the top related posts plugins
  • Step-by-step configuration tutorials
  • Customization and placement tips
  • Coding your own related posts
  • Alternate recommendations like popular and trending posts
  • A/B testing different related posts layouts
  • Troubleshooting common related posts problems
  • and much more…

Let‘s dive in!

Why Related Posts are Critical for Engagement

Here‘s an eye-opening statistic – websites that display related posts generally see a 10-30% increase in pageviews per visitor session.

According to industry research, here are some of the benefits you can expect:

Metric Potential Gain
Pageviews per session +10-30%
Time on site +25-40%
Bounce rate -15-35%

It‘s easy to understand why…

Related posts encourage visitors to keep browsing content on your site they find interesting. This directly leads to:

  • Higher user engagement – Visitors spend more time exploring your website.
  • Lower bounce rates – People are less likely to leave after reading one page.
  • Increased pageviews – Each visitor views more of your pages.
  • SEO benefits – Longer time on site signals higher quality content.

In short, related posts help convert one-and-done drive-by visitors into engaged, loyal readers.

But what‘s the best way to implement them on your WordPress site?

There are two popular options:

  1. Using a dedicated related posts plugin
  2. Manually adding related posts code

Let‘s compare the pros and cons of each method…

Related Posts Plugins for WordPress

For most websites, a plug-and-play related posts plugin is the easiest option.

Related posts plugins for WordPress handle all the complex backend queries needed to automatically detect and display engaging, relevant content for each of your posts.

Let‘s break down the top options:

1. MonsterInsights

MonsterInsights is my go-to recommendation for implementing related posts in WordPress.

Unlike plugins that only analyze your content‘s tags and categories, MonsterInsights displays posts based on actual visitor engagement and interest data from Google Analytics.

For example, if your post on "WordPress SEO Tips" is popular and attracts a ton of traffic, MonsterInsights will recognize this and may show it as a related post on other articles.

Benefits of MonsterInsights for related posts:

  • Intuitive setup – just install, connect Google Analytics, and activate related posts.
  • Zero impact on page speed if caching enabled.
  • Smart Tags show dynamic related posts per piece of content.
  • Appearance is customizable – themes, typography, styling, etc.
  • Automatic or manual placement of related posts.
  • Option to show popular products on eCommerce sites.

The best part is MonsterInsights uses the advanced RelatedVisitor algorithm that prioritizes posts your actual visitors enjoyed, not just algorithmic estimates.

This results in maximum engagement and clicks.

Step-by-Step Guide to Configuring Related Posts in MonsterInsights

  1. Install and activate the MonsterInsights plugin.
  2. Navigate to Insights > Popular Posts.
  3. Select Inline Popular Posts or the Popular Posts Widget.
  4. Choose your desired related posts theme and customize appearance.
  5. Enable caching on the Engagement tab to prevent slowing your site.
  6. Click Save Changes and visit your site to view the related posts!

Using MonsterInsights is by far the simplest option to add high-converting, engaging related posts in WordPress.

2. YARPP

YARPP (Yet Another Related Posts Plugin) is another popular related posts solution.

It uses a complex proprietary algorithm to identify semantically related content based on titles, content, tags, categories, and other data points.

Some benefits of choosing YARPP include:

  • Free basic version available.
  • Very customizable related posts templates.
  • Control over the matching algorithm and thresholds.
  • Bulk related posts re-indexing and caching.

However, there are a few downsides to YARPP:

  • Can significantly slow down your site without caching.
  • Matching is not always accurate for engagement.
  • More complex to configure than other plugins.
  • No usage analytics to optimize related posts.

How to Setup Related Posts with YARPP:

  1. Install and activate the YARPP plugin.
  2. Go to Settings > YARPP and pick your display options.
  3. Adjust match thresholds and filters if needed.
  4. Select themes and customize related posts appearance.
  5. Make sure to enable caching if you notice site slowdowns.

Overall YARPP is powerful and flexible if configured properly. But it requires more customization to achieve great results.

3. Contextual Related Posts

Contextual Related Posts is another option focused on automatically displaying relevant content without slowing down your website.

It uses a lightweight algorithm to assess relatedness based on tags, categories, content, and title similarities.

Benefits include:

  • Fast and optimized queries won‘t slow down site.
  • Choice of thumbnails, text snippets, or text only.
  • Able to exclude specific posts or categories.
  • Dynamic related posts that change based on visitor.
  • Simple settings with minimal configuration needed.

The downside is less control over the matching algorithm and related posts theme customization options. But it‘s a solid set-and-forget choice for many sites.

Related Posts Plugin Comparison

Here‘s a quick overview comparing the top three related posts plugins for WordPress:

MonsterInsights YARPP Contextual Related Posts
Algorithm method Visitor engagement data Content analysis Title + content analysis
Speed impact Low with caching Can be high Low
Customization High High Medium
Configuration needed Minimal Moderate Minimal

Manually Coding Related Posts in WordPress

Alternatively, you can take full control by manually coding your related posts in WordPress.

This avoids relying on a third-party plugin at the cost of more development work.

Here‘s an overview of how to manually code related posts:

  1. Install the WPCode snippets plugin to easily add code in WordPress without editing theme files.

  2. Use the following PHP code to query related posts by tag:

<h2>Related Posts</h2>

<?php

  $orig_post = $post;
  global $post;

  $tags = wp_get_post_tags($post->ID);

  if($tags) {
    $tag_ids = [];

    foreach($tags as $tag) {
      $tag_ids[] = $tag->term_id;
    }

    $args = [
      ‘tag__in‘ => $tag_ids,
      ‘post__not_in‘ => [$post->ID],
      ‘posts_per_page‘=> 4,
      ‘caller_get_posts‘=> 1
    ];

    $related_posts = new WP_Query($args);

    while($related_posts->have_posts()) {
      $related_posts->the_post(); ?>

      <a href="<?php the_permalink(); ?>">
        <?php the_title(); ?>  
      </a>

    <?php }
  }

  wp_reset_query();
?>
  1. Set insertion location to after content.

  2. Customize the code as needed!

This allows complete flexibility to tailor your related posts appearance, matching rules, number of posts, exclusions, and more.

The downsides are the time investment and need to know PHP and WordPress development. Maintaining custom code also requires more effort than plugins.

But for developers or advanced WordPress users, manual related posts are powerful.

Tips for Optimizing Your WordPress Related Posts

Now that we‘ve covered the best methods for adding related posts in WordPress, here are some expert tips for optimizing them.

Follow these best practices to maximize engagement and clicks:

  • Placement – Auto-inserting related posts after content generally performs best. But also test sidebars, widgets, and shortcodes.

  • Design – Make your related posts visually stand out by adding borders, background colors, dividers, and tweaking fonts.

  • Limit by time – You can exclude old articles by limiting to the past 3, 6, or 12 months.

  • Number of posts – Typically 3 to 5 related posts achieve peak engagement. Test what works.

  • Images – Enable post thumbnails to make your related posts more eye-catching.

  • Titles – For some sites, title-only related posts get more clicks than excerpts.

  • Categories – Optionally filter out certain categories like "Uncategorized" from related posts.

  • Caching – Mandatory step to avoid related posts slowing down your website.

  • A/B testing – Try different related posts plugins, numbers of posts, designs, etc and use Google Optimize or MonsterInsights to identify the best variation.

Take advantage of plugins like MonsterInsights that integrate with Google Analytics so you can track popular and engaging related posts.

Alternative Recommendations

While related posts based on content similarity are ideal for blogs – other options like popular posts and trending articles may also be effective.

Let‘s compare the benefits of each:

  • Related posts – Content relevance keeps visitors engaged. But results aren‘t always personalized or high-quality.

  • Popular posts – Showcase your successful "evergreen" content. However, these posts may not be closely related.

  • Trending posts – Timely and relevant. But trends age quickly.

Often a mix works best:

  • Related posts automatically added to broaden site navigation.
  • Curated list of 2-3 popular/trending posts to highlight timeless or timely content.

This provides both relevant discovery and your top recommendations in one module!

For ecommerce stores, you may also consider showing related products, frequently bought together products, recently viewed items, or top-selling items. The concepts are similar.

Diagnosing Common Related Posts Problems

While extremely beneficial, related posts can also introduce challenges if not properly implemented and optimized:

Inaccurate or repetitive results – Fine-tune plugin settings or switch algorithms. Manually exclude unwanted posts.

Slow page speed – Enable caching and restrict to last 12 months. Limit to 3-4 posts max. Enable lazy loading for images.

Styling issues – Use Custom CSS mods in your theme or plugin settings to fix.

Spam comments – Use a spam blocker plugin like Akismet. Close comments on ultra popular posts attracting bad bots.

Disruptive placement – Don‘t insert related posts immediately after paragraphs. Give proper spacing and separators.

Distracting design – Avoid giant images or attention-grabbing styles. Related posts should blend into your content presentation.

Carefully test and optimize your configuration. Follow WordPress speed best practices. Listen to user feedback on related posts.

Key Takeaways and Next Steps

Here are the most important things to keep in mind:

  • Related posts are proven to boost engagement, lower bounce rates, and maximize the value from your traffic.

  • Plugins like MonsterInsights and YARPP provide the most flexible options with minimal setup. But manual install is possible for developers.

  • Optimizing related post design, number, exclusion rules, caching, A/B testing, and analytics tracking is crucial.

  • Consider mixing algorithms and also showing curated popular, trending or relevant product posts.

  • Troubleshoot any speed, styling, relevance or comment spam issues that arise.

Next, spend time configuring and customizing a related posts plugin for your WordPress site.

Analyze the results in Google Analytics and keep optimizing to improve performance over time.

I hope this comprehensive guide helps you successfully add high-value related posts in WordPress! Let me know if you have any other questions.

Written by Jason Striegel

C/C++, Java, Python, Linux developer for 18 years, A-Tech enthusiast love to share some useful tech hacks.