Stock Twits User Script – Better Stock Twits

Stock Twits User Script
Stock Twits User Script

What is a Userscript?

Userscripts (a.k.a User Scripts, User scripts, or .user.js ) are open-source licensed add-ons for web browsers that change web pages as they are loaded. They give users the power to make websites do what they want them to, rather than what was originally intended.

How do I Install the Stock Twits User Script – Better Stock Twits?

You will first need a userscript manager for your browser. For Firefox, you can download Grease Monkey and for Google Chrome, you can download Tamper Monkey. After you have the manager installed, you can install Better Stock Twits by either:

  1. Installing the script from Greasy Fork and clicking Install this Script.
  2. Clicking the Icon and “Add a New Script and paste the following code in the text editor and Saving.
View Better StockTwits Source Code

// ==UserScript==
// @name Better Stocktwits
// @description Better StockTwits
// @author
// @version 0.1
// @include http*://*
// @include http*://**
// @namespace Firepetal
// ==/UserScript==
//Link Location URL’s
var NASDAQ = “”;
var GOOGLE = “”;
var YAHOO = “”;
var FINVIZ = “”;
var SALPHA = “”

//Get the div tag where we want to add our links. This will not work with IE 8 or before.
var x = document.getElementsByClassName(“ticker-container”);

//Parse the stock symbol from the URL
var symbol = window.location.pathname.match(/\/symbol\/(.*)/)[1];
for (i = 0; i < x.length; i++) {
x[i].innerHTML = x[i].innerHTML + “<b>Financials:</b>&nbsp;” +
“<a href='” + NASDAQ + symbol +”‘ target=’_blank’>Nasdaq</a>” + “&nbsp;|&nbsp;” +
“<a href='” + GOOGLE + symbol +”‘ target=’_blank’>Google Finance</a>” + “&nbsp;|&nbsp;” +
“<a href='” + YAHOO + symbol + “‘ target=’_blank’>Yahoo Finance</a>” + “&nbsp;|&nbsp;” +
“<a href='” + FINVIZ + symbol +”‘ target=’_blank’>Finviz</a>” + “&nbsp;|&nbsp;” +
“<a href='” + SALPHA + symbol +”‘ target=’_blank’>Seeking Alpha</a>”;

Is it Safe?

The Better Stock Twits script is 100% safe to use. It collects no data from you nor does it inject any malicious code. All the script does is add URL links under the stock ticker in stocktwits.

Why did you make it?

Whenever I am glutton for punishment, I like to browse stock twits and see what people are saying about certain stocks. I also like discovering some stocks that I never heard of. It got irritating when I would stumble across a new stock and would have to manually search for its financial information instead of just clicking and viewing it’s information. Of course, never trust anybody when it comes to stock, always do your own Due Diligence.


Stock Twits User Script

One thought on “Stock Twits User Script – Better Stock Twits

  1. Bill Reply

    I loved this script with the old layout of stocktwits. Was wondering if you plan to update it to be able to be used with the new stocktwits layout? Thanks.

Leave a Reply

Your email address will not be published. Required fields are marked *