Can Social Media Predict Stock Returns?

Published on March 5th, 2018

In today’s world, practically all companies have an online profile and are active on social media. Online interactions with customers are becoming increasingly important. That brings us to the following question: is there any relation between companies’ online activities and their stock returns? This is an interesting question but it might be challenging to find a clear answer. This blog post is written to facilitate research in this field.

To give you an idea about the online presence of companies: of all S&P 500 companies…

  • 96% has Twitter account, with on average 2.7 million followers
  • 81% has a Facebook account, with on average 2.6 millions likes
  • 91% has more than 20 reviews on Glassdoor, with an average of 3.45
  • 100% has a LinkedIn account

Please find below a theoretical framework on the relationship of stock returns and social media, sentiment analysis and customer & employee satisfaction.

Theoretical Framework

Social Media & Stock Returns

Many companies interact with customers on social media platforms like Twitter and Facebook. There are also numerous forums, consumer rating websites and blogs with content about companies and their products. So a huge content set is available, in addition to the conventional media like newspapers, television, and business magazines. A 2013 study shows that “overall social media has a stronger relationship with firm stock performance than conventional media while social and conventional media have a strong interaction effect on stock performance.”[1] Another study showed that social media-based metrics (web blogs and consumer ratings) are significant leading indicators of firm equity value and even have faster predictive value, i.e., shorter “wear-in” time, than conventional online media.[2] And not just the articles, but also the readers’ commentaries are relevant.[3]

Multiple studies show that you can use social media content for predictions of real-world outcomes. For example, chatter from has been used to forecast box-office revenues for movies.[4] Another one is how Facebook fan counts of the 30 most popular consumer brands is highly correlated to their respective brand company stock prices.”[5] A more recent study in 2015 shows how firm-specific social media metrics on Twitter (such as the number of followers and number of Tweets sent) is related to movement of stock prices.”[6]

Sentiment Analysis & Stock returns

The research on sentiment analysis has had a boost over the last years with the advancements in technology. It is now feasible to analyse huge amounts of textual data at very low costs. When analyzing text, volumes can already be interesting. But there is more, as some researchers state: “Social media message sentiment can contain statistically-significant ex-ante information on the future prices of the S&P500 index and a limited set of stocks, in excess of what is achievable using solely message volumes.”[7]

There are various ways to analyse sentiment and it can be useful to incorporate specific topics for companies in models.[8] So it might be interesting to base trading strategies on these results. Some researchers already used blogs and news to develop a sentiment-based market-neutral trading strategy. Those strategies had consistently favorable returns with low volatility over a long period.[9] Others used Twitter sentiment to develop a successful trading strategy, as in the examples below.


Much research has been conducted on the sentiment on Twitter. Below some examples:

  • 2011: a study on the collective mood state on Twitter and the correlation to the value of the DJIA. The researchers found an accuracy of 86.7% in predicting the daily up and down changes in the closing values of the DJIA and a reduction of the Mean Average Percentage Error (MAPE) by more than 6%.” [10]
  • 2012: researchers analyzed sentiments for more than 4 million tweets between June 2010 to July 2011 for Dow Jones Industrial Average (DJIA), NASDAQ-100 and 13 other big cap technological stocks. Their results show high correlation (up to 0.88 for returns) between stock prices and twitter sentiments.”[11]
  • 2013: researchers developed a model to predict labels (positive or negative) of future tweets. Sentiment per each day (amongst other metrics) was netted and the results show that it holds significant predictive power for subsequent stock market movement.[12]

Customer and Employee Satisfaction

Business is good when customers are happy. There is scientific evidence that customer satisfaction has a positive relationship with shareholder value.[13][14] In some earlier studies, the American Customer Satisfaction Index (ACSI) was used to measure customer satisfaction. In today’s world, it would be possible to use the user generated content on the Internet on various blogs and marketplaces to measure customer satisfaction. It is important to note that many of the relations are nonlinear and performance benefits diminish at high satisfaction levels.[15] Nevertheless, it would haven be possible to construct a portfolio that outperforms the S&P500.[16]

Besides customer satisfaction, employee satisfaction also seems to have a positive impact on a firm’s performance. In a 2003 they did a study on the “100 Best Companies to Work For in America”. In that study they found that “positive employee relations effectively serves as an intangible and enduring asset, and may, therefore, be a source of sustained competitive advantage at the firm level.”[17] To put this into numbers (from another study): “companies listed in the “100 Best Companies to Work For in America” generated 2.3% to 3.8% higher stock returns per year than their peers from 1984 through 2011.”[18]

Using web scraping to gather the data

Before we can answer the question, we need to gather data. The first step is identifying the correct online profiles of companies. You can do this by scraping their websites or by Googling their names and scraping the results. After identifying the profiles, the corresponding data can be downloaded from the APIs of the social media platforms. You can use a programming language like Python to connect to these APIs.

Next steps…

In this blog post we have constructed the theoretical framework and started the initial data gathering. The next step would be to construct time series of the social media metrics (likes, followers, grade). Then we can start exploring the correlations with stock returns. To be continued…



  1. Yu, Y., Duan, W., Cao, Q., 2013, “The impact of social and conventional media on firm equity value: A sentiment analysis approach”, Volume 55, Issue 4, Pages 919–926

  2. Luo, X., Zhang, J., Duan, W., 2013, “Social media and firm equity value”, Information Systems Research, 201324:1, 146-163

  3. Chen, H., De, P., Hu Y.J., Hwang, B.H., 2014, “Wisdom of crowds: The value of stock opinions transmitted through social media”, The Review of Financial Studies, 27 (5): 1367-1403

  4. Asur, S., Huberman, B.A., 2010, “Predicting the future with social media”, Web Intelligence and Intelligent Agent Technology (WI-IAT), 2010 IEEE/WIC/ACM International Conference

  5. O’Connor, A.J., 2013, “The power of popularity: an empirical study of the relationship between social media fan counts and brand company stock prices”, Social Science Computer Review, Vol 31, Issue 2

  6. Liu, L., Wu, J., Li, P., Li, Q., 2015, “A social-media-based approach to predicting stock comovement”, Volume 42, Issue 8, Pages 3893–3901

  7. Zheludev, I., Smith, R., Aste, T., 2014, “When can social media lead financial markets?”, Scientific Reports 4, Article number: 4213

  8. Nguyen, T.H., Shirai, K., Velcin, J., 2015, “Sentiment analysis on social media for stock movement prediction”, Expert Systems with Applications, Volume 42, Issue 24, Pages 9603–9611

  9. Zhang, W., Skiena, S., 2010, “Trading Strategies to Exploit Blog and News Sentiment”, Association for the Advancement of Artificial Intelligence, Proceedings of the Fourth International AAAI Conference on Weblogs and Social Media

  10. Bollen, J., Mao H., Zeng, X., 2011, “Twitter mood predicts the stock market”, Journal of Computational Science, Volume 2, Issue 1, Pages 1–8

  11. Rao, T., Srivastava, S., 2012, “Analyzing stock market movements using twitter sentiment analysis”, SONAM ’12 Proceedings of the 2012 International Conference on Advances in Social Networks Analysis and Mining (ASONAM 2012), Pages 119-123

  12. Makrehchi, M., Shah, S., Liao, W., 2013, “Stock prediction using event-based sentiment analysis”, Web Intelligence (WI) and Intelligent Agent Technologies (IAT), 2013 IEEE/WIC/ACM International Joint Conferences

  13. Anderson E.W., Fornell, C., 2004, “Customer satisfaction and shareholder value”, Journal of Marketing, Vol. 68, No. 4, pp. 172-185.

  14. Fornell C., Mithas S., Morgeson III, F.V., 2006, “Customer satisfaction and stock prices: High returns, low risk”, Journal of Marketing 2006 70:1, 3-14

  15. Ittner, C.D., Larcker, D.F., 1998, “Are nonfinancial measures leading indicators of financial performance? An analysis of customer satisfaction”, Journal of Accounting Research, Vol. 36, Studies on Enhancing the Financial Reporting Model (1998), pp. 1-35

  16. Aksoy, L., Cooil, B., Groening, C., Keiningham, T.L., 2008, “The long-term stock market valuation of customer satisfaction”, Journal of Marketing: July 2008, Vol. 72, No. 4, pp. 105-122.

  17. Fulmer I.S., Gerhart, B., Scott, K.S., 2003, “Are the 100 best better? An empirical investigation of the relationship between being a “great place to work” and firm performance”, Personnel Psychology, Volume 56, Issue 4, Pages 965–993

  18. Edmans, A., 2012, “The Link Between Job Satisfaction and Firm Value, With Implications for Corporate Social Responsibility”, The Academy of Management Perspectives, vol. 26 no. 41-19

Leave a Reply

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