How to estimate the cost of a Foundry agent or a Copilot agent
A costing method for agents: which meters run on each platform, how to work through tokens, retrieval and tools, and the costs everyone forgets.

- 01
Work out which cost model applies first
The question "what does this agent cost per month" has two completely different answers, and which one applies depends on where the agent runs. Establish that split before you fill in a single cell of a spreadsheet.
An agent in Microsoft Foundry behaves like an Azure workload. Costs run service by service and meter by meter: model deployments, Azure AI Search, storage, functions, monitoring and networking. They show up in Azure Cost Management and you can break them down to the resource level.
An agent in Microsoft 365 Copilot behaves like a licensing and consumption platform. Costs sit in seats, in what those seats include, and in a few consumption meters that run alongside them. You will find most of them in the Microsoft 365 admin center, not in Azure.
That difference is not cosmetic. It determines who sees the bill, which admin portal you need, and whether you can set a hard limit at all.
Diagram laden…Note the lines from the two usage meters in this diagram. They belong to Microsoft 365 Copilot capabilities but land on an Azure subscription. That is exactly the kind of cross-connection that breaks an estimate when you only look at the portal you happen to have access to.
Decisiondoes this agent run on Azure resources you manage, or on Microsoft 365 work data for licensed employees? That answer determines which of the two models you fill in. For an agent that touches both, fill in both and add them up.Notethis article deliberately quotes no rates. Microsoft Learn does not publish prices itself and consistently points to the Azure pricing calculator and the Microsoft 365 admin center, because rates vary by region, currency, model and agreement, and change regularly. An estimate built on stale numbers is more dangerous than no estimate. What you get here are the meters and the method; you pull the current rates at the moment you estimate. - 02
List the meters for a Foundry agent
Foundry Agent Service itself carries no additional charge and has no quota of its own. You pay for what the agent consumes underneath. That makes the estimate a sum of separate meters.
Meter What you pay for What drives the estimate Model inference Input, output and cached input tokens for the chosen model Calls per outcome, prompt length, answer length Hosted agents CPU and memory consumption during active sessions Session duration and the idle timeout, not replica count Code Interpreter Per session, where a session stays active for an hour How many separate sessions you open, not how many calls fit in one File Search Vector storage per GB per day The size of the vector store, not the number of queries Knowledge sources Azure AI Search, Microsoft Fabric, SharePoint, Grounding with Bing Search and licensed sources Which sources you connect, each with its own meter Tools Azure Functions, Logic Apps, your own APIs and connectors Fan-out per request and the number of retries Storage and state Blob Storage, Cosmos DB and Azure AI Search on a standard setup Whether you choose basic or standard setup Observability Log Analytics ingestion and retention How much of every prompt and tool call you write away Content Safety Per number of text records and images Whether you scan only input or also output and tool responses The first two rows are the ones most often estimated wrongly.
Notehosted agents are not billed per running hour but on CPU and memory consumption during active sessions. A session without activity ends after fifteen minutes, after which compute is released and state is preserved. The cost lever is therefore not how many agents you have deployed, but how long sessions stay active and how many run at the same time.PitfallCode Interpreter bills per session, and that session stays active for an hour. An agent that opens a fresh session per user question pays per question. An agent that reuses the session pays per hour. The same design can differ by a factor in cost without any change in functionality.Decisionbasic or standard setup? Basic uses Microsoft-managed storage and keeps your estimate short. Standard puts threads in your own Cosmos DB, files in your own Azure Storage and vector stores in your own Azure AI Search, adding three cost items you have to estimate separately. - 03
List the meters for a Microsoft 365 Copilot agent
On the Copilot side, four different billing tracks currently run alongside each other. Mixing them up is the most common mistake in estimates, because the amounts then land in the wrong portal and on the wrong department.
Track What it covers Where you manage it Licensing The Microsoft 365 Copilot add-on per user, with the built-in experiences and prebuilt agents Microsoft 365 admin center, per seat Microsoft 365 Copilot pay-as-you-go Microsoft 365 Copilot Chat, SharePoint agents and the Copilot Retrieval API in preview A linked Azure subscription Copilot Studio Agents you build in Copilot Studio, billed in Copilot Credits through prepaid capacity or pay-as-you-go Power Platform admin center, with the meter on an Azure subscription Copilot Credits in Microsoft 365 Copilot Cowork and the Work IQ API, through usage-based billing Microsoft 365 admin center, under Copilot and Cost Management More confusing still: "Copilot Credits" now appears twice in that table and they are two different things. Copilot Studio credits run through the Power Platform admin center and an Azure subscription. The Copilot Credits for Cowork and the Work IQ API run through the Microsoft 365 admin center, with their own admin portal, their own spending policies and their own purchasing model. Adding the two together as if they were one meter puts you structurally on the wrong number.
For Copilot Credit consumption in Microsoft 365, the number of credits per task depends on what the task does. Model responses, tool and skill calls, image generation and browser tasks all count towards consumption. Microsoft offers the Customer Cowork Estimator to model consumption for your own organisation. Use it rather than your own assumption about credits per task, because that number is exactly the variable an estimate falls over on.
For Copilot Studio, Microsoft Learn does publish a full rate table in credits: a classic answer costs 1, a generative answer 2, an agent action 5 and tenant graph grounding 10. For users with a Microsoft 365 Copilot licence, those four are zero-rated. That difference between licensed and unlicensed often decides the bill almost entirely, so model it separately rather than averaging across all your users.
Notesince 1 September 2025, Copilot Studio bills in Copilot Credits rather than messages. The quantity per capacity pack and the pay-as-you-go rate did not change in that conversion, only the name. So anyone still estimating in messages is doing the arithmetic right and using the wrong word, and that goes wrong the moment they open billing in the Power Platform admin center.Pitfallcapacity packs are shared with Power Platform. Capacity assigned to environments in the Power Platform admin center, or consumed there, reduces what is left for Cowork and the Work IQ API. Your available credits are therefore not your purchased credits. The Cost Management dashboard in the Microsoft 365 admin center shows what is genuinely available.Decisionpay-as-you-go, prepaid credits or existing capacity? Note that the Copilot Credit Pre-Purchase Plan sits on top of pay-as-you-go rather than replacing it: prepaid credits are consumed first and consumption continues above them. And think it through up front, because you cannot change the billing method after a spending policy has been created. You have to delete the policy and create it again. - 04
Work through the token model per scenario, not per prompt
Only now do you start calculating. Do it per business scenario, because inside an agent a single user question fans out into multiple model calls, retrievals, tool calls and retries.
The sequence per scenario is always the same:
- Number of users, and what share of them actually uses the agent. Licensed users are not active users.
- Requests per active user per month.
- Model calls per request. This is the step almost everyone sets to one. An agent with a planner, a retrieval step and a summary is already at three.
- Input tokens per call: system prompt, conversation history, retrieved context and the schemas of the tools you send along.
- Output tokens per call, and whether the model generates reasoning tokens.
- Cache hit rate, since cached input is billed at a lower rate.
- Retry factor. Estimates without retries always disappoint in production.
Multiply that out, per model, against the current rate for input, cached input and output. Work through each model separately: an agent that classifies on a small model and only routes the hard steps to a large one has two rows in your spreadsheet, not one.
Noteinput, output and reasoning tokens share the same context budget. A longer prompt therefore does not only cost more on the input side, it also leaves less room for the answer. That makes prompt length a double lever.Decisionstandard deployment or provisioned throughput? Standard bills per token and suits variable or unpredictable traffic. Provisioned bills per capacity unit per hour and only pays off at predictable, high volume. Make that call after a pilot with measured p50, p90 and p99 consumption, not before. For work that can wait, a batch deployment is a third option. - 05
Estimate retrieval separately and measure it on a sample
For a RAG agent, retrieval is often the item that determines the estimate at low volumes, because part of it is fixed and therefore keeps running even when nobody uses the agent.
Azure AI Search has two models. With dedicated capacity you pay hourly for search units, calculated as replicas times partitions, regardless of whether anyone is searching. With serverless, which is still in preview, you pay for compute units and index size. Premium capabilities such as the semantic ranker, agentic retrieval and AI enrichment are billed separately in both cases.
The method Microsoft recommends for estimating this is simple and it works: take a sample of one to five percent of your data, index it, then measure index size, throughput and cost. Extrapolate from there to the full corpus. On serverless you measure compute unit consumption through the
x-ms-request-chargeheader on your requests.Alongside search capacity, do not forget embeddings. They split into two items: the one-off embedding tokens for initial indexing, and the recurring tokens for incremental updates. That second item is the one most often skipped, and on a living dataset it is structural.
Pitfallre-embedding after a chunking change costs the full initial indexing again. Budget for it as an expected event rather than an exception, because in the first year you will almost certainly change your chunking.Decisiondedicated or serverless? Dedicated gives you a predictable monthly line and is relatively expensive per query at low volumes. Serverless scales with usage but is still in preview, which means you do not put it under a production SLA without thinking. - 06
Add the items that routinely fall outside the estimate
This is the section that moves your estimate from optimistic to usable. Walk through it literally.
- Observability. Log Analytics ingestion and retention are often the largest Azure Monitor item. Every prompt, completion and tool call you write away in full counts.
- Networking. Bandwidth, private endpoints, cross-region traffic and data movement between services.
- Storage growth. Versions, snapshots, soft delete and archive rehydration grow with time, not with usage.
- Data stores. Cosmos DB per RU/s or per consumed RUs plus storage, or Azure SQL per vCore plus storage and backup.
- Tool execution. Functions per execution and GB-seconds, Logic Apps per action and per connector, plus the downstream APIs you call yourself.
- Content Safety. Scanning every input, output, tool call and tool response multiplies the number of records.
- Environments. Dev, test, staging, load test and DR. Well-Architected Framework guidance is explicit that a cost model includes operational costs, reliability, testing, monitoring, backup and disaster recovery.
- Administration. The time spent setting up and watching budgets, tags and reporting is not an Azure meter, but it is a cost.
Decisionwhich of these do you carry as a fixed line and which as a risk buffer? Either way, put all of them in your spreadsheet, even where the value is zero. An empty line is a deliberate choice; a missing line is a surprise. - 07
Set budgets and limits before you go live
An estimate without a limit is a prediction. With a limit it becomes an agreement. And there is an asymmetry between the two platforms here that can influence your architecture choice.
On the Microsoft 365 Copilot side, usage-based billing supports budgets, alerts, spending policies and hard caps in the Microsoft 365 admin center. You can genuinely make consumption stop. Worth knowing: spending policies only set limits, they do not reserve credits. And a running task that goes over a user's limit is allowed to finish and is then not billed.
On the Azure side it is different. Azure Cost Management has budgets and alerts, but they signal rather than stop. Microsoft states explicitly that Azure OpenAI does not offer a hard limit of the kind that exists elsewhere. If you want consumption to actually stop, you build that yourself with an action group that triggers automation.
Get your allocation right at the same time. Every Foundry project is tagged automatically with a
projecttag you can filter on in Cost Analysis; that chargeback capability is still preview and only works for models sold by Azure, not for marketplace models. You will find Azure OpenAI in Cost Management under Cognitive Services, where you filter on service tier. Meters appear as a model name with a GUID, one per model per Foundry resource. Meters for partner and community models attach to the resource group rather than the Foundry resource, so scope your analysis to the resource group.Notethat asymmetry belongs in your risk section. A scenario where a loop can run away is a technical risk you have to cover yourself on Azure, and a setting on Microsoft 365 Copilot.Decisionwho gets the bill? If the answer is "the department that uses the agent", arrange tags and allocation before the first resource is created. Adding tags afterwards leaves you with a period without history.
Cost profile per architecture pattern
The pattern you choose determines which item dominates. Use this table to see where your estimate is most sensitive.
| Pattern | Cost profile | Biggest risk |
|---|---|---|
| Simple question-and-answer agent | Almost entirely model tokens and basic monitoring | Long prompts, long answers and retries |
| RAG agent | Model tokens plus search capacity, embeddings and index storage | Over-indexing, large chunks, repeated re-embedding |
| Multi-agent system | Multiple model calls, planner calls and intermediate messages | Token multiplication across agent loops |
| Workflow agent | Model plus Functions, Logic Apps and connectors | Every action path opens its own meter |
| Autonomous agent | Runtime, long-running tasks, grounding and tools | Loops without an upper bound and repeated tool use |
| Multi-model solution | Small model for routing, large model for the hard steps | Poor routing that reaches for the expensive model too often |
| Human-in-the-loop | Extra workflow and notification cost | Approval flows, logging and audit retention |
The biggest levers are always the same: which model, how large the context, how many model calls per completed outcome, how retrieval is set up, how many tools fire per request, how much you log, and whether you can use built-in Microsoft 365 behaviour instead of rebuilding grounding and governance in Azure.
Foundry or Microsoft 365 Copilot?
The platform choice is an architecture choice, but it has direct cost consequences.
| Choose Microsoft Foundry when | Choose Microsoft 365 Copilot when |
|---|---|
| You need your own UX, external users, your own APIs, your own memory or your own RAG | The agent is mainly for employees and belongs in Copilot Chat, Teams, Microsoft 365 apps or SharePoint |
| You want to optimise at token, model, retrieval and infrastructure level | You want per-seat predictability and built-in Microsoft 365 governance |
| You want to bring your own Azure services such as Functions, Cosmos DB, SQL or API Management | You want business users to build lightweight internal agents themselves |
| Volume is high but the tasks are simple enough to route to small models | The value comes from Microsoft 365 work data and its compliance boundaries |
| You need granular FinOps tags and per-workload allocation | You want budgets, alerts and hard caps you can set in the admin center |
As a rule of thumb: if the agent is mainly about Microsoft 365 work data for licensed employees, start with Microsoft 365 Copilot. If the agent is a product, part of an application, an external assistant or a heavily integrated Azure workload, model it as a Foundry agent.
How to structure your spreadsheet
Work with eight tabs, in this order. The split is deliberate: you want one place where assumptions live and one place where outcomes live.
- Scenario inputs. Users, active ratio, working days, sessions per user, prompts per session, model, region, deployment type.
- Token model. Average system prompt, user prompt, retrieved context, tool schemas, output, reasoning and cache hit rate.
- Retrieval model. Data in GB, number of documents, chunks, embedding tokens, index size, search configuration, semantic ranker and agentic retrieval.
- Tools and workflow. Functions executions and GB-seconds, Logic Apps actions and connectors, API calls, retry factor.
- Storage and data. Blob GB and transactions, Cosmos RUs, SQL vCores, storage and backup.
- Microsoft 365. Seats, Copilot Chat users, pay-as-you-go usage, Copilot Credits and capacity packs.
- Operations. Monitoring in GB per day, retention in days, Content Safety calls, networking in GB, and a multiplier for dev, test and DR.
- Outcomes. Monthly run rate, cost per user, per active user, per request, per completed outcome, plus a sensitivity table.
The last line is the most important one. The most useful metric for an architect is cost per completed outcome, not cost per interaction. A single user question can fan out into multiple model calls, retrievals, tool calls, retries and log entries. So keep both the number of raw interactions and the number of completed cases in your spreadsheet. That matches Well-Architected Framework guidance to associate costs with business metrics and to keep scenario analysis in the cost model.
Three mistakes you can avoid
Estimating per prompt rather than per outcome. A prompt is not a unit of work. Calculate per completed business outcome and count the calls inside it.
Lumping the Copilot billing tracks together. Copilot Credits for Cowork and the Work IQ API run through the Microsoft 365 admin center. Copilot Studio credits run through the Power Platform admin center and an Azure subscription, and pay-as-you-go usage for Copilot Chat and SharePoint agents runs through its own billing policy in the Microsoft 365 admin center. Different portals, different roles, different reporting.
Leaving out the non-production footprint. Dev, test, staging, load test and DR simply keep running. On many agent platforms that is a substantial share of the monthly run rate, particularly when monitoring and private endpoints live there too.
Wrapping up
An agent estimate that holds up is not a pricing exercise but an architecture exercise. The numbers follow from the design: how many model calls per outcome, how large the context, how retrieval is set up, how much you log and which platform the agent belongs on. Fix those choices first, then fill in the current rates, and check the estimate against what you actually measure after a pilot.
If you then want to allocate those costs to departments, read How to set up chargeback and showback. For the model choice itself, How to choose an LLM is the follow-up, and the underlying discussion is in Can you estimate AI costs before you go to production?.
If you would rather watch the arithmetic move before you put it in a spreadsheet, the Pricing Simulations in the Architecture Lab hold two estimators, one for a Foundry agent and one for an agent on Microsoft 365 Copilot. They run on the same published rates and show per line how the number adds up.
Sources
- Microsoft Foundry Agent Service FAQ
- Hosted agents in Microsoft Foundry
- Plan and manage costs for Microsoft Foundry
- Manage costs for Azure AI Search
- Microsoft 365 Copilot pay-as-you-go meters
- Copilot Studio: billing rates and management for Copilot Credits
- Licensing for agents powered by the standard harness
- Usage-based billing and cost management for Copilot Credits
- Managing AI experiences enabled by usage-based billing
- Manage Copilot Cowork for your organization
- Create a cost model with the Well-Architected Framework
The process at a glance
Click a step for its key decision
Work out which cost model applies first
does this agent run on Azure resources you manage, or on Microsoft 365 work data for licensed employees? That answer determines which of the two models you fill in. For an agent that touches both, fill in both and add them up.
Read next
Related patterns
Related use cases
Related best practices
