voyager
Easy-to-use, fast, simple multi-platform approximate nearest-neighbor search library.
What it is and what it does
Voyager is a production-grade library for approximate nearest-neighbor search on vector embeddings, built on the HNSW algorithm and used at Spotify to handle hundreds of millions of queries daily. It wraps the open-source hnswlib with additional convenience features and maintains feature parity between Python and Java implementations, making it suitable for both single-machine and distributed systems that need fast similarity lookups on embedding data.
The library is designed for in-memory operation, meaning vectors are loaded into RAM for query speed. It supports multiple distance metrics (e.g., cosine, Euclidean) and is optimized for recall-accuracy tradeoffs typical of approximate search. Installation is straightforward via pip on supported platforms (Linux, macOS, Windows), with pre-built wheels for Python 3.7–3.12, though it does depend on numpy and compiled C++ bindings.
Use it for:
- Powering recommendation systems by finding similar user embeddings or item embeddings in real time.
- Semantic search over document embeddings to retrieve relevant results faster than exact similarity.
- Duplicate detection by indexing embeddings and querying for near-neighbors to identify similar content.
- Machine learning feature retrieval, retrieving nearest neighbors in embedding space for classification or clustering tasks.
- Real-time personalization by querying user preference embeddings against product or content embeddings.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Voyager performs fast approximate nearest-neighbor searches on in-memory vector collections using the HNSW algorithm, enabling efficient similarity queries on embedding data.
Yes. Voyager is production-ready, actively maintained, permissively licensed, and has no known vulnerabilities. It offers a clean API for a common and performance-critical task (approximate nearest-neighbor search). Install it if you need fast vector similarity queries on embeddings; the medium install friction is offset by broad platform coverage and proven scale at Spotify.
Install
voyager on PyPI
pip
pip install voyageruv
uv add voyagerpoetry
poetry add voyagerInstalling voyager
Before you install
Medium install friction due to compiled C++ bindings, but pre-built wheels cover Python 3.7–3.12 across Linux (x86_64, ARM), macOS (Intel, ARM), and Windows (x86_64). Actively maintained with recent commits and production use at scale.
License in practice
Licensed under Apache 2, a permissive open-source license allowing commercial and private use with minimal restrictions—suitable for most projects without legal concern.
Quickstart
pip install voyager
import voyager
import numpy
index = voyager.Index(space='cosine')
index.add(vectors)
nearest = index.query(query_vector, k=10)
Requires numpy; compiled wheels are available for common platforms, but installation may require a C++ compiler on unsupported architectures.
Verify before relying
- Whether the package supports dynamic index updates (add/remove vectors after initial build) or requires rebuild.
- Memory overhead and scalability limits for very large vector collections.
- Tuning guidance for HNSW parameters (M, ef_construction, ef) for different use cases.
- Performance comparison specifics with other approximate nearest-neighbor libraries beyond the ann-benchmarks reference.
Package facts
| License | not declared (permissive) |
| Python support | not specified |
| Install friction | medium — platform-specific wheel |
| Runtime dependencies | 1 — numpy |
| Maintenance | actively maintained — 609 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 117,976/month — #12,140 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: voyager-2.1.0-cp310-cp310-macosx_10_13_universal2.whl; voyager-2.1.0-cp310-cp310-macosx_10_13_x86_64.whl; voyager-2.1.0-cp310-cp310-macosx_11_0_arm64.whl; voyager-2.1.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl; voyager-2.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; voyager-2.1.0-cp310-cp310-win_amd64.whl; voyager-2.1.0-cp311-cp311-macosx_10_13_universal2.whl; voyager-2.1.0-cp311-cp311-macosx_10_13_x86_64.whl; voyager-2.1.0-cp311-cp311-macosx_11_0_arm64.whl; voyager-2.1.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl; voyager-2.1.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; voyager-2.1.0-cp311-cp311-win_amd64.whl; voyager-2.1.0-cp312-cp312-macosx_10_13_universal2.whl; voyager-2.1.0-cp312-cp312-macosx_10_13_x86_64.whl; voyager-2.1.0-cp312-cp312-macosx_11_0_arm64.whl; voyager-2.1.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl; voyager-2.1.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; voyager-2.1.0-cp312-cp312-win_amd64.whl; voyager-2.1.0-cp37-cp37m-macosx_10_13_x86_64.whl; voyager-2.1.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Tags
More Database Engines/Servers packages
DuckDB is an in-process SQL database engine…
permissive · top 1,000 on PyPI
pymssqlpymssql provides a Python DB-API interface to…
copyleft · top 1,000 on PyPI
mysqlclientmysqlclient provides a Python interface to…
copyleft · top 1,000 on PyPI
sqlmodelSQLModel combines SQLAlchemy and Pydantic to…
permissive · top 5,000 on PyPI
tinydbTinyDB is a lightweight, pure-Python document…
permissive · top 5,000 on PyPI
vertica-pythonNative Python client library for connecting to…
permissive · top 5,000 on PyPI
nmslibnmslib provides efficient similarity search in…
unclear · top 15,000 on PyPI
pyspark-hnswProvides a PySpark-compatible implementation of…
unclear · top 15,000 on PyPI
usearchUSearch provides approximate nearest-neighbor…
permissive · top 15,000 on PyPI
annoyAnnoy searches for approximate nearest…
permissive · top 5,000 on PyPI
hnswlibFast approximate nearest neighbor search using…
unclear · top 15,000 on PyPI
cuvs-cu12Provides GPU-accelerated approximate nearest…
permissive · top 15,000 on PyPI
scannScaNN performs efficient vector similarity…
permissive · top 15,000 on PyPI
kdtreeConstructs, modifies, and searches…
permissive · top 15,000 on PyPI
lunrLunr is a lightweight, in-memory full-text…
permissive · top 15,000 on PyPI
turbopufferProvides a Python client library for the…
permissive · top 5,000 on PyPI