textblob
Simple, Pythonic text processing. Sentiment analysis, part-of-speech tagging, noun phrase parsing, and more.
What it is and what it does
TextBlob is a Python library that wraps NLTK and pattern to provide a simplified interface for common natural language processing tasks. It lets you work with text through an intuitive API, extracting linguistic features like parts of speech, noun phrases, and sentiment polarity from strings without deep NLP expertise.
The library handles tokenization, tagging, phrase extraction, and sentiment scoring out of the box. It also supports text classification, spelling correction, word inflection, and n-gram analysis. You create a TextBlob object from a string and access properties like .tags, .noun_phrases, and .sentences.sentiment to get results. It requires downloading linguistic corpora once after installation.
Use it for:
- Analyze sentiment polarity of customer reviews or social media posts to gauge positive/negative feedback
- Extract key noun phrases from documents for topic identification or keyword extraction
- Tag parts of speech in text for grammatical analysis or downstream NLP pipelines
- Classify text documents using built-in Naive Bayes or Decision Tree classifiers
- Correct spelling errors and normalize text before further processing
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
TextBlob provides a simple API for common natural language processing tasks including sentiment analysis, part-of-speech tagging, noun phrase extraction, tokenization, and text classification.
Yes, if you need straightforward NLP tasks without deep learning complexity. TextBlob is well-maintained, has no security vulnerabilities, and offers a gentle entry point to text processing. Install it for sentiment analysis, phrase extraction, or basic classification. Skip it if you require state-of-the-art accuracy or modern transformer-based models.
Install
textblob on PyPI
pip
pip install textblobuv
uv add textblobpoetry
poetry add textblobInstalling textblob
Before you install
Low install friction with a single runtime dependency on nltk. The project is actively maintained with a recent release (27 days old) and a substantial repository history since 2013, indicating stable long-term support.
License in practice
MIT license permits commercial and private use with minimal restrictions, making it suitable for most projects without licensing concerns.
Quickstart
pip install textblob
python -m textblob.download_corpora
from textblob import TextBlob
blob = TextBlob('The movie was great!')
print(blob.sentiment.polarity)
Requires Python 3.10 or later. The download_corpora step must be run once to fetch required linguistic data before sentiment analysis and other NLP features work.
Verify before relying
- Performance characteristics on large text volumes or real-time processing scenarios
- Accuracy of sentiment analysis and classification compared to modern transformer-based alternatives
Package facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=3.10) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 1 — nltk |
| Maintenance | actively maintained — 27 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 7,600,176/month — #1,717 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: textblob-0.20.1-py3-none-any.whl
Keywords: textblob, nlp, linguistics, nltk, pattern
Tags
More Linguistic packages
Detects and normalizes text encoding from…
permissive · top 100 on PyPI
tiktokentiktoken is a fast BPE tokenizer that converts…
permissive · top 1,000 on PyPI
chardetDetects character encoding and language in byte…
permissive · top 1,000 on PyPI
text-unidecodeConverts Unicode text to ASCII by…
copyleft · top 1,000 on PyPI
larkLark is a parsing library that builds abstract…
permissive · top 1,000 on PyPI
tree-sitterPython bindings to the tree-sitter parsing…
permissive · top 1,000 on PyPI
nltkNLTK is a Python library for natural language…
permissive · top 1,000 on PyPI
soynlpUnsupervised Korean natural language processing…
copyleft · top 15,000 on PyPI
polyglotPolyglot is a multilingual natural language…
copyleft · top 15,000 on PyPI
pyviProvides Vietnamese language processing tools…
permissive · top 15,000 on PyPI
spark-nlpSpark NLP provides distributed natural language…
permissive · top 5,000 on PyPI
pythainlpPyThaiNLP provides Thai-language natural…
permissive · top 5,000 on PyPI
azure-ai-textanalyticsProvides Python bindings to Azure's cloud-based…
permissive · top 15,000 on PyPI
flairFlair is a PyTorch-based NLP framework that…
permissive · top 15,000 on PyPI
vaderSentimentVADER performs lexicon and rule-based sentiment…
permissive · top 5,000 on PyPI
textacytextacy extends spaCy's NLP capabilities with…
permissive · top 15,000 on PyPI