pysolr
Lightweight Python client for Apache Solr
Decision gist · record as of 2026-08-14
Yes, if you are already running Apache Solr and need a Python client. The package is actively maintained, has no known vulnerabilities, uses a permissive license, and is stable (Production/Stable status). The main barrier is the strict Python 3.10+ requirement and the need for an external Solr server; if those are met, it is a straightforward, reliable choice for Solr integration.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires a running Apache Solr server accessible at the URL you provide; Python 3.10+ and Requests 2.32.5+ are also required.
- High install friction: requires Python 3.10+ and Requests 2.32.5+.
- The package is actively maintained (last commit 2026-08-07, 269 days since latest release) with stable production status, but the strict version requirements and external Solr server dependency mean setup is non-trivial.
License · maintenance · safety
BSD (permissive) — BSD license (permissive) means you can use, modify, and distribute pysolr freely in commercial and private projects with minimal restrictions, provided you include the license notice.
last release 2025-11-18 (269 days) · last repo commit 2026-08-07 · 701 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 352,813 downloads/mo, #7,307 on PyPI
Alternatives
Verify before relying
pip install pysolr
import pysolr
solr = pysolr.Solr('http://localhost:8983/solr/', always_commit=True)
solr.ping()
results = solr.search('bananas')
for result in results:
print(result['title'])- Whether optional dependencies (simplejson, kazoo) are automatically installed or require explicit installation for their respective features.
- Performance characteristics and scalability limits for large document sets or high-query-volume scenarios.
- Compatibility with specific Solr server versions beyond the general 'Apache Solr' reference.
What it is and what it does
pysolr is a Python wrapper around Apache Solr's HTTP API that handles the low-level details of communicating with a Solr search server. It lets you index documents, search them with Lucene-style queries, and manage the index through a simple Python interface. The package abstracts away HTTP request construction and response parsing, so you work with Python objects and method calls instead of raw JSON.
Typical workflows involve creating a Solr client instance pointing to your server, adding or updating documents in batches, and then running searches with optional parameters like highlighting or faceting. It supports both standalone Solr instances and SolrCloud deployments with Zookeeper coordination. The package requires an external Solr server to be running—it is not a search engine itself, only a client library.
Use it for
- Index and search documents in a web application backed by Apache Solr without writing HTTP request code.
- Perform full-text search queries with faceting, highlighting, and spelling correction on large document collections.
- Manage multi-core or SolrCloud deployments by routing queries and updates to the correct collection or core.
- Implement batch document ingestion pipelines that add, update, or delete documents in Solr with custom commit policies.
- Build autocomplete or typeahead features using custom Solr request handlers through pysolr's handler configuration.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes, if you are already running Apache Solr and need a Python client.
The package is actively maintained, has no known vulnerabilities, uses a permissive license, and is stable (Production/Stable status). The main barrier is the strict Python 3.10+ requirement and the need for an external Solr server; if those are met, it is a straightforward, reliable choice for Solr integration.
Install
pysolr on PyPI
Before you install
High install friction: requires Python 3.10+ and Requests 2.32.5+. The package is actively maintained (last commit 2026-08-07, 269 days since latest release) with stable production status, but the strict version requirements and external Solr server dependency mean setup is non-trivial.
Requires a running Apache Solr server accessible at the URL you provide; Python 3.10+ and Requests 2.32.5+ are also required.
License in practice
BSD license (permissive) means you can use, modify, and distribute pysolr freely in commercial and private projects with minimal restrictions, provided you include the license notice.
Quickstart
pip install pysolr
import pysolr
solr = pysolr.Solr('http://localhost:8983/solr/', always_commit=True)
solr.ping()
results = solr.search('bananas')
for result in results:
print(result['title'])
Verify before relying
- Whether optional dependencies (simplejson, kazoo) are automatically installed or require explicit installation for their respective features.
- Performance characteristics and scalability limits for large document sets or high-query-volume scenarios.
- Compatibility with specific Solr server versions beyond the general 'Apache Solr' reference.
Package facts
| License | BSD permissive |
| Python support | Supports the current Python release >=3.10 |
| Install friction | High. Source build required |
| Runtime dependencies | 2 packagesrequestssetuptools |
| Maintenance | Actively maintained 269 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 352,813 / month, #7,307 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 5 - Production/StableIntended Audience :: DevelopersLicense :: OSI Approved :: BSD LicenseOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3Topic :: Internet :: WWW/HTTP :: Indexing/Search |
Evidence: pysolr-3.11.0.tar.gz
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “solr python client”
- pysolrpysolr is a lightweight Python client for Apache Solr that enables…
- sqlalchemy-solrProvides a SQLAlchemy dialect that allows you to query Apache Solr…
- django-haystackHaystack provides a unified search API for Django that lets you swap…
Give your agent the search over MCP, or paste the wish link into any chat.
More Indexing/Search packages
Provides stemming algorithms for 34 languages, reducing word variants to a common stem for text search and indexing applications.
Install it if you need stemming for search or text indexing.
Represents and manipulates IPv4, IPv6, MAC addresses and related network objects; supports CIDR notation, subnetting, set operations, IANA lookups, and DNS reverse generation.
Client library for the Firecrawl API that scrapes, crawls, and searches the web, returning clean Markdown or structured data; also indexes research papers from PubMed, bioRxiv, medRxiv, and arXiv.
Aggregates web search results from multiple search engines (Bing, DuckDuckGo, Google, Brave, and others) through a single Python API, with optional distributed caching via DHT network.
Install it if you need programmatic multi-engine search; skip it only if you require a single specific search engine's API or have strict Windows-only requirements.
Retrieves search results from DuckDuckGo for text, images, videos, and news without requiring an API key.
Install only if you have an existing dependency or need to maintain legacy code.
A Python HTTP client for interacting with Algolia's search API, supporting both synchronous and asynchronous operations with built-in request handling and response parsing.
See also sqlalchemy-solr · elasticsearch · elasticsearch9 · metal-sdk · django-haystack · Whoosh · modelsearch · kazoo · pagefind · Whoosh-Reloaded