When you have a threaded comment system, how do you decide whether you collapse replies to top level comments or no?


Comment 1
    Comment 1.1
    Comment 1.2
    Comment 1.3 
Comment 2

vs some kind of collapsed threads (sometimes they show 1 or 2 of second-level replies)

Comment 1
   --Show replies
Comment 2
   --Show replies

This answer provide a great link on the topic, but it’s rather overview than actionable info.

Is there any sort of guidelines when it’s better to collapse thread vs to leave it fully open? Does it depends on the site type, e.g. news sites seem to show all threads open, and social media like Facebook or Instagram mostly collapse?

  • 2
    There are different metrics that can be used to determine whether to collapse or expand these sorts of comment threads. If you have some ranking on the comments (vote up or down) you can collapse comments that are below a certain threshold. If there is no ranking, then that is when you might expand most, but you could limit it to a certain level down the tree - e.g. expand 1st and 2nd level comments, but collapse and click to expand 3rd or lower.
    – Dwev
    Commented Jan 17, 2018 at 15:06
  • 1
    doesn't answer your question, but worth a read: "Comment threads: good, bad, or not at all?" blogs.scientificamerican.com/a-blog-around-the-clock/… Commented Feb 23, 2018 at 15:49
  • 1
    And here is the article I was actually looking for, on why comment threading is horrible: blog.codinghorror.com/discussions-flat-or-threaded Commented Feb 23, 2018 at 16:00

2 Answers 2


I don't think there is an exact algorithm, but I think (if you must have comment sub-threads) it should be that they are visible by default, but hideable when you've read them.

In those heady days before Facebook, I used to use phpBB, where there was no subthreading, though you could (iirc) mention someone (tag them) and quote a snippet of their post. People used to actually read all the posts on a thread before commenting, and actually post well-thought-out answers to questions.

With Facebook sub-threading (and the fact that they hide many of the previous comments on a post), one often ends up replying with the same comment over and over again, especially if the comments get heated.

Disqus subthreading seems a lot better, in that they don't hide comments (but subthreads do sometimes end up in the wrong order).

WordPress comments seem to only go to two levels of replies (probably wise).

So, my advice, don't hide any comments; don't have too many nested levels of subthreading; and moderate comments to avoid trolls and derailers.

This is based on my experience of discussions in comments, and the following articles:

If you're building software with social components, plan for the worst kinds of behavior from your users from the start. At least lay the groundwork for technological and social controls to handle those inevitable issues, or you'll eventually regret it. -- Jeff Atwood


When to collapse
If under the content, which contains all the comments, follows other content. So the user can either read the comments if he's interested or scroll to the next content.

Example Facebook:
Facebook collapses the comments on the timeline. This is because the user usually scrolls through all the posts and only read the comments of those posts where he's interested in.

When to show it all
If there is no relevant content that follows the comments. This is mostly the case when you are in a detail view of a post or article.

Example News Site:
In an article on a news site, at the bottom is mostly the comment section where all the comments are shown. This is because after an article, mostly you go back to the overview, unless you're interested in the comments. So they display all comments expanded, in order to let the user scan through the comments and maybe step in to the conversation.

Don't forget the quantity
Maybe you think "but there are websites which collapse comments on the detail page", like quora.
Here you need to think about what kind of comment the user will post. Do the comments itself represent something worth knowing? If yes, the comments on this comment are a conversation about the answer and not primarily interesting for the user. So collapse it and set the focus on the important comment.
On reddit or also Medium, the answers aren't collapsed, because those are more of a conversation between users about the topic of the content. So it could be more interesting for the user to read all comments without the extra click to expand.

mobile / desktop
A more obvious point is the mobile / desktop talk:
You have more space on the desktop to scroll through a collapsed conversation. On mobile, the site could get extremely long to scroll through, so maybe collapse the comments there.

Final though
Think about what you want to achieve. Then look up similar applications to yours and see how they've done it. And think about why they done it that way and what the users want to achieve.
There is, as always, no "one fits all" solution.

  • Great point about feed vs single page, though it seems news sites (e.g. Quartz, although I'm not sure if they have comments) adapt the practice of infinite feeds, where one news piece follows another on scroll. So more and more newspapers / magazines seem to collapse comments by default now.
    – Runnick
    Commented Mar 7, 2018 at 9:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.