5

As for now, I'm following many answers in a specific question, for example here: Visual design changes to the review queues

But I just lost my curiosity of this particular discussion. So how can I unfollow all answers to this particular discussion?

As for now, I found one similar question here: Is there a way to unfollow notifications on a particular post

But the answer IMHO is not related to my question. So I decided to ask here. Is there an answer for me?

4
  • 4
    To clarify: are you asking how to do this for all the followed answers on a post at once, as opposed to unfollowing each one manually?
    – cigien
    Commented Mar 5, 2021 at 18:50
  • 1
    Exactly this one. Commented Mar 5, 2021 at 19:29
  • 2
    The easiest way would be to go to /users/current?tab=following and then click Unfollow > Unfollow > Unfollow. This will be easier than going through the (long) answers in the post, checking if they're followed, and then unfollowing them.
    – 41686d6564
    Commented Mar 6, 2021 at 6:19
  • 1
    Well, the really quick and dirty way to do it would be to execute the following in the browser's console: $('.answer .js-follow-post:contains(Following), .answer .js-follow-post:contains(following)').click(). However, that just quickly clicks all the "following" buttons on the current page. It doesn't account for the possibility that there might be multiple pages of answers, or that there might be limits to how quickly you can unfollow a bunch of posts (i.e. it ignores that there might be any type of rate limiting).
    – Makyen
    Commented Mar 14, 2021 at 21:55

2 Answers 2

10

If you’re asking how to unfollow all answers of a specific question at once, there’s no built-in way to do this, currently.

However, it is still theoretically possible, using this dirty hack:

No guarantee that this will work! Visit the timeline of the question, then open the browser console (dev tools) (hit F12) and run this in the console:

const formData = new FormData(),
  answerIds = Array.from(document.querySelectorAll("td.creation-date a[href^='#answer_']"))
    .map((link) => link.getAttribute("href").split("_")[1]);

formData.append("fkey", StackExchange.options.user.fkey);

const interval = setInterval(() => {
    if(answerIds.length === 0){
      clearInterval(interval);
      console.log("Done.");
    }
    else{
      const currentAnswerId = answerIds.pop();
      
      fetch(`${location.origin}/posts/${currentAnswerId}/vote/${StackExchange.vote.voteTypeIds.follow}?undo=true`, {
        method: "POST",
        body: formData
      })
        .then(() => console.log(`Unfollowing answer ${currentAnswerId}.`));
    }
  }, 1000); // Add some delay to avoid rate limiting.
            // Going below that may work if there are only at most 10 answers;
            // if there are a lot more answers, I’d recommend a higher delay.

Wait for the script to finish (message “Done.”) and that should unfollow all answers on a question (excluding the question itself). It finds all the undeleted answers, and also the deleted answers if you have the 10k privilege.


The follow feature has been introduced here: The Follow Questions and Answers feature is now live across the Network.

To unfollow a post, just click the “Following” link under the posts you’re following:

Tooltip “Unfollow this question to stop receiving notifications”.

(same thing for answers:)

Tooltip “Unfollow this answer to stop receiving notifications”.

or visit your profile page under “Activity” → “Following” where you have kebab menus1 with the "Unfollow" button in the right column.


This is also explained in the tooltip that appears when following a post:

Tooltip.

You’re following this question

You’ll receive notifications when there’s activity on this post.

Manage followed posts in your profile.


[Unfollow]


1 The kebab menu is three vertical dots and should not be confused with the meatballs menu, which is three horizontal dots. (Source)

3
  • 1
    It seems they are looking for a way to unfollow all the answers of a specific question using a single action. Commented Mar 5, 2021 at 19:28
  • Yeah. this is the feature I'm looking for. Commented Mar 5, 2021 at 19:31
  • 3
    About the code: no guarantees! I’m not sure if this will 100 % work, and I’m not sure if the interval is enough to avoid rate limiting. Commented Mar 5, 2021 at 19:36
5

So how to unfollow all answers in this this particular discussion?

You can't. You have to manually unfollow each one separately.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .