Pinecone
Inspect Pinecone vector index statistics
Use Pinecone’s index stats endpoint or Python SDK to read the vector count, dimensions, namespace counts, and fullness fields.
Documentation reviewed · 2 methods with sources
Ways to do it
API
POST /describe_index_stats
Call the data-plane host for an index and return its vector count, dimensions, namespace counts, and fullness fields.
Read source: Pinecone get index stats API- Requirements
- A Pinecone API key, the data-plane hostname for the index, and the API version header.
- Limitations
- Serverless indexes do not support filtering describe-index-stats. For serverless on-demand indexes, fullness values are typically 0 because capacity scales automatically.
Example shell
curl --fail -X POST "https://$PINECONE_INDEX_HOST/describe_index_stats" \
-H "Api-Key: $PINECONE_API_KEY" -H "X-Pinecone-Api-Version: 2025-10"SDK
Index.describe_index_stats()
Use the Pinecone Python Index client to retrieve the same index statistics as a typed SDK response.
Read source: Pinecone Python Index reference- Requirements
- Python, the pinecone package, a Pinecone API key, and an Index client initialized against the target index host.
- Limitations
- Vector counts can lag recent writes. Leave the filter argument unset.
Example text
import os
from pinecone import Pinecone
pc = Pinecone(api_key=os.environ["PINECONE_API_KEY"])
index = pc.Index(host=os.environ["PINECONE_INDEX_HOST"])
print(index.describe_index_stats())