# pgvector

> Open-source vector similarity search for Postgres

Source: https://talira.ai/catalog/pgvector-vv3axms1
Every listing: https://talira.ai/catalog.md

- Kind: Open source
- Types: Plugin
- Categories: [databases / vector](https://talira.ai/categories/databases/vector), [databases / postgres / extensions](https://talira.ai/categories/databases/postgres/extensions)
- Platforms: linux, macos, windows, docker[^3]
- Licence: PostgreSQL[^4]
- Pricing: Free and open source[^4]
- Free tier: yes[^4]
- Self-hostable: yes[^3]
- Creator: Andrew Kane

pgvector is a [PostgreSQL](https://talira.ai/catalog/postgresql-cm55wcnd.md) extension for storing embeddings and searching them by similarity, next to the rest of your data. It adds `vector`, `halfvec`, `bit` and `sparsevec` types, exact and approximate nearest-neighbour search with HNSW and IVFFlat indexes, and L2, inner product, cosine, L1, Hamming and Jaccard distances, with Postgres's transactions, joins and point-in-time recovery. It supports Postgres 13 and later, comes with Postgres.app and many hosted Postgres providers, and has client libraries for dozens of languages. Andrew Kane created it, under the PostgreSQL License.

## Links

- GitHub: https://github.com/pgvector/pgvector

## Ways to install

### Package managers

- [Homebrew](https://talira.ai/catalog/homebrew-djy17yn9.md): <https://formulae.brew.sh/formula/pgvector>[^1]
- [APT](https://talira.ai/catalog/apt-d7essv0z.md): <https://packages.debian.org/source/stable/pgvector>[^2]

## Problems it solves

- store embeddings in the Postgres database we already run instead of adding a vector database
- semantic search over our documents with SQL
- nearest-neighbour search on millions of embeddings with an approximate index
- filter similarity search results by tenant or other columns in the same query
- combine keyword full-text search and vector search in Postgres for hybrid search
- keep embeddings transactional with the rows they describe, with backups and replication
- find similar products, images or users by their embedding
- reduce the memory our vector index needs with half-precision or binary quantization

## Features

- vector, halfvec, bit and sparsevec types
- exact and approximate nearest neighbour search
- HNSW and IVFFlat indexes
- L2, inner product, cosine, L1, Hamming and Jaccard distances
- iterative index scans for filtered queries
- binary quantization and half-precision indexing
- client libraries for many languages

## Limitations

- Doesn't index full-precision vectors over 2,000 dimensions: use half-precision (up to 4,000) or binary quantization (up to 64,000)[^3]

## Trust

Overall: 0.23 out of 1.
Signals: backing 0.20, extensibility 0.00.

- created by Andrew Kane

Warnings:

- GitHub activity not fetched yet

## Related

- Works with [PostgreSQL](https://talira.ai/catalog/postgresql-cm55wcnd.md)

## Alternatives

- [Chroma](https://talira.ai/catalog/chroma-m7z06vjv.md): Open-source search infrastructure for AI
- [Pinecone](https://talira.ai/catalog/pinecone-pz5r9gym.md): The trusted AI knowledge platform
- [Qdrant](https://talira.ai/catalog/qdrant-fte3azxr.md): High-performance, massive-scale vector database and vector search engine for the next generation of AI
- [Weaviate](https://talira.ai/catalog/weaviate-b62zbjhc.md): The AI database developers love
- [LanceDB](https://talira.ai/catalog/lancedb-x2r3sbm7.md): Developer-friendly OSS embedded retrieval library for multimodal AI. Search More; Manage Less.
- [Milvus](https://talira.ai/catalog/milvus-y366wb6h.md): A high-performance, cloud-native vector database built for scalable vector ANN search

## Sources

[^1]: https://formulae.brew.sh/api/formula.json (checked 21 Nov 2026)
[^2]: https://deb.debian.org/debian/dists/stable/main/source/Sources.xz (checked 21 Nov 2026)
[^3]: https://github.com/pgvector/pgvector (checked 19 Nov 2026)
[^4]: https://github.com/pgvector/pgvector/blob/master/LICENSE (checked 19 Nov 2026)
