Optimizing Threads: Hiding The For You Page

/ Notebook

Optimizing Threads: Hiding The For You Page

Threads has become an interesting, active platform in a short period of time. However, with the lack of control of a sticky Following feed that I have control over, my signal to noise ratio in my feed is about 10% of the posts I see. The For You algorithm is way too optimized toward lizard brain content; it's not a worthy way to use your brain time.

I hope this changes someday, but historical Meta decisions make me believe this won't happen. So instead, I created a userscript and userstyle to limit Threads to just a Following feed in your browser.

How To Use Userscripts

For Chromium-based browers, you can use the extension User Javascript and CSS. An alternative extension to look at would be Tampermonkey.

The Userscript

This script looks for the "For You" section of the page, and removes it if it's the first of two divs. The goal here is to have a focused Threads experiences, and thus the limitation here is that you cannot use it with multiple columns.

// ==UserScript==
// @name     Remove "For You" Section from Threads.net
// @namespace  
// @version    1.0
// @description  Removes the "For You" section if it's the first of two divs and shows main content
// @match    https://www.threads.net/*
// @grant    none
// ==/UserScript==

(function() {
  'use strict';

  function showMainContent() {
    const mainDiv = document.querySelector('body > div[id^="mount_"]');
    if (mainDiv) {
      mainDiv.classList.add('content-loaded');
    }
  }

  function removeForYouSection() {
    const forYouLink = document.querySelector('a[href="/for_you"][role="link"][tabindex="0"]');
    if (forYouLink) {
      let elementToRemove = forYouLink;
      
      // Go up 5 levels of parents
      for (let i = 0; i < 5; i++) {
        if (elementToRemove.parentElement) {
          elementToRemove = elementToRemove.parentElement;
        } else {
          break; // Stop if we can't go up further
        }
      }
      
      // Check if the element to remove is a div and is the first of two divs
      if (elementToRemove.tagName === 'DIV' && 
        elementToRemove.parentElement && 
        elementToRemove.parentElement.children.length === 2 &&
        elementToRemove.parentElement.firstElementChild === elementToRemove) {
        
        // Remove the element
        elementToRemove.remove();
      }
    }

    // Make the main content visible
    showMainContent();
  }

  // Run the function immediately
  removeForYouSection();

  // If the site uses dynamic loading, you might need to run the function periodically
  setInterval(removeForYouSection, 100);
})();

The Userstyles

This is the related CSS to add to optimize the experience. By using CSS, this runs earlier than the script.

// ==UserStyles==

body > div[id^="mount_"] {
  visibility: hidden !important;
  background: #000 !important;
}

body > div[id^="mount_"].content-loaded {
  visibility: visible !important;
}

I hope this allows you for a more focused, enjoyable experience on Threads. If you have any questions, or want to talk more about this, please reach out. And if you remix this, I’d love to see what you come up with!

Contact

You can find me on the following networks, or drop me a line at hello@maykelloomans.com.

Hi! Hey! Wow. Fancy finding you here at the bottom of the page. Can't believe you made it this far! Whew. This site is being designed and iterated on in public. If you see something that looks off, please reach out and let me know!

Built with NextJS, hosted on Vercel. Analytics by Splitbee.
Photos powered by Shoebox.

© 2003 - 2025 Maykel Loomans