All Microsoft exams

Microsoft DP-420: Building AI Applications with Azure Cosmos DB

What the DP-420 exam covers and what it costs, with a free 30-question practice test and an explanation for every answer.

At a glance
Level
Associate
Topic areas
3
Free practice questions
30
Full question bank
100 questions

What the DP-420 exam covers

The topic areas in our DP-420 question bank, with each one's share of the 100 practice questions.

DP-420 cost and format

Exam codeDP-420
CertificationAzure Cosmos DB AI Developer Associate
VendorMicrosoft
LevelAssociate
StatusActive

Last checked October 22, 2026 against the official Microsoft exam page.

DP-420 sample questions

The first 5 questions from the free practice test. Open a question to see the answer and why it is right.

All 30 free questions
  1. Question 1Design and develop database solutions

    A globally distributed application must guarantee that reads never lag writes by more than five minutes or a fixed number of versions, while keeping latency lower than strong consistency. Which consistency level fits this requirement?

    1. AEventual
    2. BStrong
    3. CBounded staleness
    4. DConsistent prefix
    Show answer and explanation
    Correct answer: C

    Bounded staleness lets the team configure a maximum lag in time or versions, which gives a predictable freshness guarantee with lower latency than strong. Eventual has no bound, and consistent prefix guarantees order but not a time limit.

  2. Question 2Secure, optimize, and deploy database solutions

    An application running in Azure must access Azure Cosmos DB without storing account keys in its configuration. Which approach is recommended?

    1. AUse the account connection string in a public GitHub repository with sample code files
    2. BShare the account's read-write key with every developer so each can test locally
    3. CEmbed the primary key in the compiled application binary so it ships with each release
    4. DUse a managed identity with Microsoft Entra ID authentication and disable key-based authentication
    Show answer and explanation
    Correct answer: D

    Managed identities with Entra ID remove long-lived secrets from application code and allow access to be governed by role assignments. Embedded or shared keys create exposure that identity-based access avoids.

  3. Question 3Implement AI and analytics capabilities in database solutions

    An application wants to store vector embeddings and query them with a vector index. Which container-level element must be defined when the container is created?

    1. AA separate Azure Cosmos DB account for each embedding dimension, each with its own throughput
    2. BA nightly script that regenerates the embeddings from the source documents and writes them back
    3. CA cloud-based image classifier hosted in Azure Machine Learning to tag photos
    4. DThe vector embedding policy that describes the vector path, dimensions, and data type
    Show answer and explanation
    Correct answer: D

    The vector embedding policy and matching vector index are part of the container definition, which the vector search depends on. The other options are unrelated to the container configuration.

  4. Question 4Design and develop database solutions

    Which consistency level is the default when a new Azure Cosmos DB for NoSQL account is created?

    1. ASession
    2. BEventual
    3. CBounded staleness
    4. DStrong
    Show answer and explanation
    Correct answer: A

    Session is the default and guarantees read-your-own-writes for a client session. Strong and bounded staleness are stricter options, and eventual is weaker than the default.

  5. Question 5Secure, optimize, and deploy database solutions

    A reporting service needs read-only access to items in one container and must not be able to write data. Which control provides the narrowest appropriate permission?

    1. AGrant the service owner rights across the whole Azure subscription scope
    2. BGive the service the account's primary key to use for data access
    3. CAssign a data-plane role-based access control role that grants read access only
    4. DAllow read-write access to the container and rely on code to avoid unneeded writes
    Show answer and explanation
    Correct answer: C

    Data-plane role-based access control assigns read-only data roles that can be scoped, which enforces least privilege. Full keys and subscription ownership grant far more than the service needs.

How to prepare for DP-420

  1. Read the official Microsoft outline first (exam page), so you know exactly what is in scope.
  2. Give the most time to Design and develop database solutions and Secure, optimize, and deploy database solutions: together they make up 74% of the questions.
  3. Take the free 30-question practice test and note which topics you miss.
  4. Go back to the weak topics, then test again. A practice score shows where to study; it does not predict your exam result.

Full DP-420 question bank

All 100 questions with answers and explanations, as a PDF, an online practice exam, or both.

Full question bank · 100 questions
$75$104

Both formats together. The best value.

Instant access after payment, with 90 days of updates. Checkout is on our store, AIExamCerts.

DP-420 FAQ