Increase JetPacks Amount of Related Posts in WordPress

By default the related posts module from JetPack shows 3 related posts at the end of a regular single post in WordPress. You can use a JetPack filter to increase the amount of JetPack related posts with  – jetpack_relatedposts_filter_options.

You would use it like so…

Just change the number to how many related posts you want to appear.

There are a number of convenient JetPack filters available, another one is to change the related posts main headline from “Related” to someting else with jetpack_relatedposts_filter_headline

Both of these snippets are to be added to your themes functions.php file.

JetPacks CSS Layout

One of the issues you will run into when changing the amount of related posts is how JetPack controls the layout with CSS selector pseudo nth types – you will have to disable JetPacks CSS or write your own to override JetPacks – for instance to have a 6up layout that reduces without gaps when the viewport is smaller you will need to add in your CSS..

How your CSS files load will determine if you need to add the !important variable or not.

8 Comments

  1. Raj on March 10, 2023 at 4:50 pm

    Why would I want to use custom CSS with Jetpack?

  2. Raju Chaurasia on March 10, 2023 at 4:46 pm

    Thanks for this post.

  3. blissyung on April 19, 2020 at 6:25 pm

    This was very helpful, I can’t believe after so many years they still haven’t added this to the default settings.

    Is there anyway we can strip “Title and description ALT”? and secondly set title limit it’s pretty annoying for post with long titles.

    Thanks for this post.

  4. Tim on October 17, 2019 at 3:20 am

    Thanks so much Neil, the 6 block CSS Layout worked perfectly.

  5. Kris Fannin on April 24, 2016 at 4:13 pm

    Very thankful for this as everything else I found was wanting to change Jetpack files – wanted something that would stick through updates. Thank you again for this!

  6. Potato on March 31, 2016 at 6:19 am

    Thanks for the snippet Neil, not sure why this isn’t in Jetpack by default yet.

  7. Joseph on January 4, 2016 at 3:47 am

    Great tip. On some mobile devices, the related posts appear like this: http://prntscr.com/9lu53l missing on slot. How can we make it fill up/responsive?

    Regards,

    • Neil Gowran on January 5, 2016 at 12:30 am

      Thanks for pointing that out – you have to adjust some CSS to override JetPacks styling – I have updated the post and added some CSS to make the 6up layout work.

Leave all Comment