skillfed

elasticsearch5

Python client for Elasticsearch

elasticsearch5 v5.5.6 77.9K downloads/30d#14,480 on PyPI4,385
Permissive license Apache License, Version 2.0 Active released

What it is and what it does

elasticsearch5 is the official low-level Python client for Elasticsearch 5.x. It provides a thin, opinion-free wrapper around the Elasticsearch REST API, handling connection pooling, automatic node discovery, load balancing across cluster nodes, and serialization of Python data types to JSON. The package includes features like persistent connections, thread safety, SSL/HTTP authentication support, and a pluggable architecture for customization.

This is a foundational library meant to be used directly for low-level cluster operations or as a base for higher-level abstractions. It has no external runtime dependencies, making installation straightforward. However, it is explicitly designed for Elasticsearch 5.x; if you are running a newer Elasticsearch version, you will need a different client package.

Use it for:

  • Indexing and querying documents in an Elasticsearch 5.x cluster from Python applications.
  • Managing indices, mappings, and cluster settings programmatically via the Elasticsearch API.
  • Building custom search applications that need direct control over connection pooling and node selection.
  • Integrating Elasticsearch into Python services that require thread-safe, persistent cluster communication.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Low-level Python client for Elasticsearch 5.x that handles connection management, request translation, and cluster communication with configurable load balancing and node discovery.

Yes, if you are running Elasticsearch 5.x and need a low-level Python client. The package is stable, permissively licensed, and has no external dependencies. However, if you are using a newer Elasticsearch version, do not install this—it will not work. If you need a higher-level query DSL, consider elasticsearch-dsl instead, which builds on top of this client.

Install

elasticsearch5 on PyPI

pip

pip install elasticsearch5

uv

uv add elasticsearch5

poetry

poetry add elasticsearch5

Installing elasticsearch5

Before you install

Low install friction with no runtime dependencies. Repository is active with recent commits, though the package itself has not been updated since 2019 and targets the now-obsolete Elasticsearch 5.x series.

License in practice

Licensed under Apache License, Version 2.0 (permissive). You can use, modify, and distribute this package freely in commercial and private projects with minimal restrictions.

Quickstart

pip install elasticsearch5

from elasticsearch import Elasticsearch

es = Elasticsearch()
es.indices.create(index='my-index', ignore=400)
es.index(index='my-index', doc_type='test-type', id=42, body={'data': 'value'})

Requires a running Elasticsearch 5.x server; the package is designed for that version specifically and will not work with newer Elasticsearch releases.

Verify before relying

  • Whether Elasticsearch 5.x is still in use in your environment or if you need a client for a newer Elasticsearch version.
  • Current compatibility with modern Python versions beyond those listed in classifiers (2.6–3.6).

Package facts

License Apache License, Version 2.0 (permissive)
Python support not specified
Install friction low — pure-Python wheel
Runtime dependencies none
Maintenance actively maintained — 2,635 days since the last release
Last repo commit
First released
Downloads 77,932/month — #14,480 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: elasticsearch5-5.5.6-py2.py3-none-any.whl

Development Status :: 5 - Production/StableIntended Audience :: DevelopersLicense :: OSI Approved :: Apache Software LicenseOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 2Programming Language :: Python :: 2.6Programming Language :: Python :: 2.7Programming Language :: Python :: 3Programming Language :: Python :: 3.2Programming Language :: Python :: 3.3Programming Language :: Python :: 3.4Programming Language :: Python :: 3.5Programming Language :: Python :: 3.6Programming Language :: Python :: Implementation :: CPythonProgramming Language :: Python :: Implementation :: PyPy

Tags

elasticsearch python clientelasticsearch 5.x connectorelasticsearch api wrapperelasticsearch cluster clientelasticsearch connection management
elasticsearchsearch-enginedeprecated-version

More Database packages