---
id: "mongodb/voyage-code-4"
also: ["voyageai/voyage-code-4-20260812"]
cheapest_list_usd_per_m: "0.12 in, 0.0 out, at voyageai on openrouter"
cheapest_effective_usd_per_m: "0.1199 in, 0.0 out, at voyageai on openrouter"
context: 32000
max_output: 28800
input: ["text"]
output: ["embeddings"]
released: "2026-08-13"
api: ["/api/v1/embeddings"]
endpoints: 1
gateways: "openrouter (1)"
no_training: 1
trains: 0
retains_prompts: 1
---
# VoyageAI by MongoDB: voyage-code-4

voyage-code-4 is a code embedding model from Voyage AI, a MongoDB company. It is designed for coding agents and code retrieval, with Matryoshka embeddings at 2048t voyage-code-4 here: [mongodb.com/products/platform/ai-search-and-retrieval/models](https://www.mongodb.com/products/platform/ai-search-and-retrieval/models?utm_source=openrouter&utm_medium=referral)