Published on in Vol 9 (2025)

Preprints (earlier versions) of this paper are available at https://preprints.jmir.org/preprint/50536, first published .
Exploring Public Sentiment on the Repurposing of Ivermectin for COVID-19 Treatment: Cross-Sectional Study Using Twitter Data

Exploring Public Sentiment on the Repurposing of Ivermectin for COVID-19 Treatment: Cross-Sectional Study Using Twitter Data

Exploring Public Sentiment on the Repurposing of Ivermectin for COVID-19 Treatment: Cross-Sectional Study Using Twitter Data

Research Letter

1Unit of Global Health, Department of Health Sciences, University Medical Center Groningen, University of Groningen, Groningen, The Netherlands

2Department of Pharmaceutics and Pharmaceutical Technology, Faculty of Pharmacy, Universitas Padjadjaran, Sumedang, Indonesia

3Center of Excellence in Higher Education for Pharmaceutical Care Innovation, Universitas Padjadjaran, Bandung, Indonesia

4Department of Pharmacology and Clinical Pharmacy, Faculty of Pharmacy, Universitas Padjadjaran, Sumedang, Indonesia

5Department of Economics, Econometrics and Finance, Faculty of Economics and Business, University of Groningen, Groningen, Indonesia

6Center for Health Technology Assessment, Universitas Padjadjaran, Universitas Padjadjaran, Bandung, Indonesia

*these authors contributed equally

Corresponding Author:

Angga Prawira Kautsar, MBA

Unit of Global Health, Department of Health Sciences

University Medical Center Groningen

University of Groningen

Antonius Deusinglaan 1

Groningen, 9713 AV

The Netherlands

Phone: 31 0503611111

Email: angga.prawira@unpad.ac.id


A sentiment analysis of 5051 Twitter posts from January 2022 found that 53.4% of them expressed positive views on ivermectin as a COVID-19 treatment, 35.6% of them were neutral, and 11% of them were negative, highlighting the polarized public perception and the need for careful interpretation of social media data in health communication.

JMIR Form Res 2025;9:e50536

doi:10.2196/50536

Keywords



As the COVID-19 pandemic evolves, the scientific community confronts the limitations of vaccines due to emerging viral mutations that potentially decrease vaccine efficacy [Jiang S. Don't rush to deploy COVID-19 vaccines and drugs without sufficient safety guarantees. Nature. Mar 16, 2020;579(7799):321-321. [CrossRef] [Medline]1], thus necessitating a parallel investigation into additional therapeutic agents. Ivermectin, a well-established, safe drug, has emerged as a repurposed drug candidate due to preliminary studies suggesting its antiviral properties against SARS-CoV-2 in vitro [Jiang S. Don't rush to deploy COVID-19 vaccines and drugs without sufficient safety guarantees. Nature. Mar 16, 2020;579(7799):321-321. [CrossRef] [Medline]1,Caly L, Druce JD, Catton MG, Jans DA, Wagstaff KM. The FDA-approved drug ivermectin inhibits the replication of SARS-CoV-2 in vitro. Antiviral Res. Jun 2020;178:104787. [FREE Full text] [CrossRef] [Medline]2]. Nonetheless, the scientific debate remains vigorous, with discussions on the drug’s appropriate formulation and dosing for potential COVID-19 prophylaxis and treatment [The WP. NIH trial may settle debate over ivermectin as a covid-19 treatment. The Washington Post. URL: https://www.washingtonpost.com/health/2021/04/08/ivermectin-covid-drug/ [accessed 2023-03-06] 3].

Simultaneously, ivermectin’s role has garnered widespread attention on social media, reflecting the public's quest for alternative treatments. Twitter (now X), a hub for real-time public discourse, has become a fertile ground for divergent views on COVID-19 treatment [de Melo T, Figueiredo CMS. Comparing news articles and tweets about COVID-19 in Brazil: sentiment analysis and topic modeling approach. JMIR Public Health Surveill. Feb 10, 2021;7(2):e24585. [FREE Full text] [CrossRef] [Medline]4,Garcia K, Berton L. Topic detection and sentiment analysis in Twitter content related to COVID-19 from Brazil and the USA. Appl Soft Comput. Mar 2021;101:107057. [FREE Full text] [CrossRef] [Medline]5]. This sentiment analysis focuses on Twitter discussions about ivermectin, showing public opinion that, while not devoid of misinformation risks, these discussions offer an alternative lens to understand the societal pulse on this contentious topic [Hill S, Scott R. Developing an Approach to Harvesting, Cleaning, and Analyzing Data from Twitter Using R. Inf Sys Educ J. 2017;15(3):15.6]. By examining the sentiments expressed on Twitter, we aim to add nuance to the ongoing discourse, acknowledging the platform's influence on public perception and its implications for health communication strategies.


Overview

This cross-sectional examined the COVID-19–related sentiments on ivermectin using Twitter data. Primary data were collected from Twitter posts about ivermectin worldwide from January 15 to 22, 2022. We searched posts with the keyword “ivermectin” and retrieved raw data with various variables. Data cleaning involved lowercasing capital letters, eliminating retweet symbols, removing punctuation marks, and other preprocessing steps to ensure data accuracy [Hill S, Scott R. Developing an Approach to Harvesting, Cleaning, and Analyzing Data from Twitter Using R. Inf Sys Educ J. 2017;15(3):15.6]. People’s sentiments were determined by creating a corpus (body of text) and loading a lexicon dictionary based on the positive and negative words. The sentiment score was calculated with the Bing method using a range of –6 to +6 and considered 3 sentiment types: positive, neutral, and negative [Liu B, Hu M, Cheng J. Opinion observer: analyzing and comparing opinions on the Web. 2005. Presented at: WWW '05: Proceedings of the 14th international conference on World Wide Web; May 10-14, 2005:342-351; Chiba, Japan. [CrossRef]7,Liu B. Sentiment Analysis: Mining Opinions, Sentiments, and Emotions. Cambridge, United Kingdom. Cambridge University Press; 2020. 8]. The Bing lexicon was chosen for its proven effectiveness and simplicity in extensive dataset analysis. Frequency analysis of single terms (unigrams), word pairs (bigrams), and bigram networks helped identify frequently mentioned terms and explore relationships between words [Liu B, Hu M, Cheng J. Opinion observer: analyzing and comparing opinions on the Web. 2005. Presented at: WWW '05: Proceedings of the 14th international conference on World Wide Web; May 10-14, 2005:342-351; Chiba, Japan. [CrossRef]7,Liu B. Sentiment Analysis: Mining Opinions, Sentiments, and Emotions. Cambridge, United Kingdom. Cambridge University Press; 2020. 8]. Despite its simplicity, this approach is as robust as more complex methods, as it accurately categorizes sentiments and identifies patterns through unigram and bigram frequency analysis [Hill S, Scott R. Developing an Approach to Harvesting, Cleaning, and Analyzing Data from Twitter Using R. Inf Sys Educ J. 2017;15(3):15.6]. This computational analysis–focused methodology offers valuable insights into public sentiment, complementing traditional clinical evaluation without extensive statistical validation. Data were mined using Twitter’s limited application programming interface (version 2) and analyzed using RStudio (R Foundation) and relevant packages for visualization.

Ethical Considerations

There was no direct connection with Twitter users. We removed all individual data, usernames, IDs, and tweets in the manuscript and supporting material. Therefore, ethical approval was not required.


In total, 5051 ivermectin-related tweets underwent sentiment analysis, revealing a prevailing positive sentiment (53.4%), followed by neutral (35.6%) and negative (11%) sentiments among the analyzed tweets (Figure 1). The analysis identified frequently mentioned positive terms such as “medication,” “potentially,” and “treatment,” while negative terms like “poised,” “smuggling,” and “toxic” were less common. Notably, analysis of word pairings unveiled strong associations with positive sentiments, further supporting the notion of ivermectin’s potential efficacy in COVID-19 treatment. Examining these word pairings facilitated in-depth exploration of sentiment patterns within the bigram network, revealing significant connections and relationships in the analyzed tweets (Figure 2).

Figure 1. Distribution of sentiment score.
Figure 2. Bigram count network related to tweets ivermectin.

Principal Findings

Our analysis shows that tweets about repurposing ivermectin for COVID-19 treatment are predominantly positive. Terms like “medication,” “potentially,” and “treatment” frequently appeared in positive contexts, reinforcing this finding. Phrases such as “ivermectin works,” “available ivermectin,” and “ivermectin medication” were strongly associated with positive sentiment. These results align with previous findings showing ivermectin’s popularity on Twitter for COVID-19 treatment [de Melo T, Figueiredo CMS. Comparing news articles and tweets about COVID-19 in Brazil: sentiment analysis and topic modeling approach. JMIR Public Health Surveill. Feb 10, 2021;7(2):e24585. [FREE Full text] [CrossRef] [Medline]4,Garcia K, Berton L. Topic detection and sentiment analysis in Twitter content related to COVID-19 from Brazil and the USA. Appl Soft Comput. Mar 2021;101:107057. [FREE Full text] [CrossRef] [Medline]5]. However, some negative sentiment was observed, particularly concerning warnings from the Food and Drug Administration and the limited clinical evidence supporting ivermectin’s efficacy in COVID-19 prevention and treatment [Why You Should Not Use Ivermectin to Treat or Prevent COVID-19. Food and Drug Administration. URL: https:/​/nycourts.​gov/​reporter/​webdocs/​Why-You-Should-Not-Use-Ivermectin-to-Treat-or-Prevent-COVID-19.​pdf [accessed 2022-03-01] 9].

Twitter data have proven valuable in monitoring public responses to the COVID-19 pandemic, as evidenced by a study of millions of SARS-CoV-2–related tweets [Xue J, Chen J, Hu R, Chen C, Zheng C, Su Y, et al. Twitter discussions and emotions about the COVID-19 pandemic: machine learning approach. J Med Internet Res. Nov 25, 2020;22(11):e20550. [FREE Full text] [CrossRef] [Medline]10]. This study not only identified dominant topics like new cases, death rates, and preventive measures, but also explored the geographic distribution of sentiments through tweet-embedded geolocation data (code available in

Multimedia Appendix 1

Code in R.

ZIP File (Zip Archive), 5 KBMultimedia Appendix 1).

Limitations

Of note, the findings are based on Twitter data, which may not represent the entire population’s sentiments. Therefore, researchers conducted cross-validation of the sources.

Conclusions

This sentiment analysis highlights the polarized perception of ivermectin in COVID-19–related discourse and reflects broader public health debates. Given the regulatory advisories and the limited clinical evidence, these public sentiments must be interpreted cautiously.

Acknowledgments

We acknowledge receiving the Ministry of Higher Education, Science, and Technology Overseas Postgraduate Education scholarship (DIKTI BPP-LN grant T/915/D3.2/KD.02.01/2019) awarded to AK. Despite this financial support, we have diligently maintained transparency and objectivity in our work.

Conflicts of Interest

None declared.

Multimedia Appendix 1

Code in R.

ZIP File (Zip Archive), 5 KB

  1. Jiang S. Don't rush to deploy COVID-19 vaccines and drugs without sufficient safety guarantees. Nature. Mar 16, 2020;579(7799):321-321. [CrossRef] [Medline]
  2. Caly L, Druce JD, Catton MG, Jans DA, Wagstaff KM. The FDA-approved drug ivermectin inhibits the replication of SARS-CoV-2 in vitro. Antiviral Res. Jun 2020;178:104787. [FREE Full text] [CrossRef] [Medline]
  3. The WP. NIH trial may settle debate over ivermectin as a covid-19 treatment. The Washington Post. URL: https://www.washingtonpost.com/health/2021/04/08/ivermectin-covid-drug/ [accessed 2023-03-06]
  4. de Melo T, Figueiredo CMS. Comparing news articles and tweets about COVID-19 in Brazil: sentiment analysis and topic modeling approach. JMIR Public Health Surveill. Feb 10, 2021;7(2):e24585. [FREE Full text] [CrossRef] [Medline]
  5. Garcia K, Berton L. Topic detection and sentiment analysis in Twitter content related to COVID-19 from Brazil and the USA. Appl Soft Comput. Mar 2021;101:107057. [FREE Full text] [CrossRef] [Medline]
  6. Hill S, Scott R. Developing an Approach to Harvesting, Cleaning, and Analyzing Data from Twitter Using R. Inf Sys Educ J. 2017;15(3):15.
  7. Liu B, Hu M, Cheng J. Opinion observer: analyzing and comparing opinions on the Web. 2005. Presented at: WWW '05: Proceedings of the 14th international conference on World Wide Web; May 10-14, 2005:342-351; Chiba, Japan. [CrossRef]
  8. Liu B. Sentiment Analysis: Mining Opinions, Sentiments, and Emotions. Cambridge, United Kingdom. Cambridge University Press; 2020.
  9. Why You Should Not Use Ivermectin to Treat or Prevent COVID-19. Food and Drug Administration. URL: https:/​/nycourts.​gov/​reporter/​webdocs/​Why-You-Should-Not-Use-Ivermectin-to-Treat-or-Prevent-COVID-19.​pdf [accessed 2022-03-01]
  10. Xue J, Chen J, Hu R, Chen C, Zheng C, Su Y, et al. Twitter discussions and emotions about the COVID-19 pandemic: machine learning approach. J Med Internet Res. Nov 25, 2020;22(11):e20550. [FREE Full text] [CrossRef] [Medline]

Edited by A Mavragani; submitted 05.07.23; peer-reviewed by R Gore, J Plasek, A Naser, B Cao; comments to author 16.11.23; revised version received 12.02.24; accepted 09.09.24; published 27.03.25.

Copyright

©Angga Prawira Kautsar, Rano Kurnia Sinuraya, Jurjen van der Schans, Maarten Jacobus Postma, Auliya A Suwantika. Originally published in JMIR Formative Research (https://formative.jmir.org), 27.03.2025.

This is an open-access article distributed under the terms of the Creative Commons Attribution License (https://creativecommons.org/licenses/by/4.0/), which permits unrestricted use, distribution, and reproduction in any medium, provided the original work, first published in JMIR Formative Research, is properly cited. The complete bibliographic information, a link to the original publication on https://formative.jmir.org, as well as this copyright and license information must be included.