Delete a namespace
For guidance and examples, see Manage namespaces.
Note: This operation is not supported for pod-based indexes.
PINECONE_API_KEY="YOUR_API_KEY"
INDEX_HOST="YOUR_INDEX_HOST"
NAMESPACE="YOUR_NAMESPACE" # To target the default namespace, use "__default__".
curl -X DELETE "https://$INDEX_HOST/namespaces/$NAMESPACE" \
-H "Api-Key: $PINECONE_API_KEY" \
-H "X-Pinecone-Api-Version: 2026-07"DELETE /namespaces/{namespace}
Parameters
Section titled “Parameters”X-Pinecone-Api-Version(header, string, required) — Required date-based version headernamespace(path, string, required) — The namespace to delete. Must be ASCII, must not contain the NUL character, and must be 1-512 characters long.
Responses
Section titled “Responses”200— A successful response.400— Bad request. The request body included invalid request parameters.401— Unauthorized. Possible causes: missing or invalid API key.404— Namespace not found. No namespace of the given name exists on the index.4XX— An unexpected error response.5XX— An unexpected error response.