Skip to main content

Billing and cost management

This topic describes how to query billing details, analyze bills, and stop billing.

Query bills

Bills are generated only after a call is completed. Bills for model inference are generated with minute-level granularity, typically within 2 to 10 minutes. Bills for services such as batch inference, model training, and knowledge base are generated hourly. During peak business hours, the time displayed in the system is considered the final billing time.

Cost Overview

Log on to the Model Studio console. In the left-side navigation pane, choose Cost and Usage > Cost Overview. The page shows costs for model calls, model training, and model deployment.
  1. Select a statistical period and time range. You can view data by minute, hour, day, or month: minute supports up to 1 day, hour up to 7 days, day up to 31 days, and month up to 12 months.
  2. Select a grouping dimension: by model, product category, API Key, workspace, region, or service site. API Keys are displayed by ID, not in plaintext.
  3. View the cost cards:
    • Total Cost: The total cost for the selected time range. You can click Go to Invoice.
    • Subscription Cost: Subscription fees for Token Plan, provisioned throughput, model units, savings plans, and similar items.
    • Bill Cost: Pay-as-you-go costs for model calls, training, and deployment.
  4. View Bill Trend: Shows only post-paid bill amounts and excludes subscription fees. Bills for the current month may be delayed.
  5. To set a budget or alert, go to Budget Management.
To view earlier costs or calculate total historical spending, export bills month by month from the Alibaba Cloud Expenses and Costs Billing Details page and aggregate them manually:
  1. Go to Expenses and Costs > Billing Details.
  2. Set Product Name to Alibaba Cloud Model Studio.
  3. Switch the billing month one at a time and export each month's bill as a CSV file. For the export steps, see Billing Details.
  4. Sum the exported data across all months to obtain your total historical spending.
All statistical period options on the Billing Details page are scoped to a single month, so cross-month aggregation is not supported and must be done manually after exporting each month. In the export dialog box, you can select content from the last 18 months for batch export.

Bill details

On the Cost Overview page, click View details to open the Bill details page. Bill details are displayed by model calls, model training, provisioned throughput units, and dedicated throughput units. The page includes only post-paid bill costs and excludes prepaid orders. Only data from April 1, 2026 onward is available.
  • Filters: Filter by API Key, model, inference type, and time range. Inference types include real-time inference, offline batch inference, and online batch inference.
  • Table columns: Time, model, inference type, specification, workspace, billed usage, and payable amount. Specification indicates billing specifications such as input/output, cache hits, and video resolution.
  • View calculation: Click Details for a row to open the Cost details - model name drawer. View Payable amount = Total catalog usage price - Total discounts, along with the calculation of original usage, usage after free quota deduction, total catalog usage price, and payable amount. Total discounts include savings plan deductions, promotional offers, and coupons. If all usage is covered by the free quota, the usage after free quota deduction is 0 and the payable amount is 0.
  • Download: Click the download icon in the upper-right corner to export bills under the current filters. Click Download records to view exports from the last 7 days.
  • Duration-based billable items: On the model training, provisioned throughput unit, and dedicated throughput unit tabs, select By minute for billable items charged by usage × duration. When you query by month, day, or hour, duration information is temporarily unavailable.
Some fields in Bill details may be incomplete. For complete fields, go to the Billing Details page in Alibaba Cloud Expenses and Costs and check the instance ID rules in Billing details below.

Billing details

Bills for large model inference and training can be broken down for review by API Key ID, workspace ID, model name, input/output type, invocation channel.

1. Download the bill

  1. On the Billing Details page, select a billing period.
  2. Select Product as Alibaba Cloud Model Studio, and click Search.
  3. In the upper-right corner of the bill list, click the Export Bill CSV to download the bill.
  4. Open the file, locate the Instance ID column, and interpret it using the rules described in the next section.

2. Interpret key fields

The field format described in this section applies to model inference bills. The instance ID format for model training and fine-tuning bills is different (it uses an exclamation mark ! as the delimiter). Other billable items, such as Token Plan, knowledge base, and web search, also use different instance ID formats and are not covered by this section.
The "Instance ID" field uses semicolons (;) as delimiters. From left to right, the segments are ApiKeyID;workspace ID;model name;input/output type;invocation channel;free quota exhaustion flag. The segments have the following meanings:
  1. ApiKeyID: The ID of the API key used for the call. If this segment is empty, the call did not use an API key and typically came from the console. If it is not empty, the call was made from code, and you can use this ID to identify the specific API key.
  2. Workspace ID: The workspace that the call belongs to (for example, llm-xxx). A workspace is the smallest unit for permission management (models and users) and for cost allocation in Alibaba Cloud bills.
  3. Model name: The model used for the call, for example, qwen-max.
  4. Input/output type: The billable usage type for this bill entry, such as input tokens (input_token) or output tokens (output_token).
  5. Invocation channel: The entry point that initiated the call. For common values, see Invocation channel descriptions below.
  6. Free quota exhaustion flag: 0 indicates that the feature is disabled, and 1 indicates that it is enabled.
Some bills omit trailing empty fields, so the actual number of segments may be less than six. If the fifth segment is 0 or 1, it is the free quota exhaustion flag and the invocation channel is empty. If the fifth segment is a channel code, it is the invocation channel and the free quota exhaustion flag is empty. Bills for tasks such as batch inference and model evaluation may be generated later than the call time. The actual bill is authoritative. Examples:
  • 1210386;llm-xxx;qwen-max;output_token;bailian-claude-code-proxy;0
  • ;llm-xxx;qwen-max;input_token;aicenter;0
  • 53618;llm-xxx;qwen-max;output_token;;0

3. Data traceability and terms

  • Query API Key: Copy the ApiKeyID from your bill and go to the API Key page to find the corresponding key name.
  • Query workspace: Copy the workspace ID from your bill. Go to the Workspaces page to identify the specific workspace.
  • Invocation channel descriptions:
    • Empty: A call made through the API.
    • aicenter: A call made from the Experience Center in the console.
    • assistant-api: A call made via the Assistant API.
    • responses: A call made through the Responses API.
    • evalModel: A call made through model evaluation.
    • batch: A call made through batch inference.
    • bailian-claude-code-proxy: A call made through the Anthropic-compatible API.
    • app: A call made from an application.
    • agent1: A call made through an agent application (Agent 1.0).
    • agent2: A call made through the new agent application (Agent 2.0).
    • managed agent: A call made through a ManagedAgent managed agent.
    • RAG: A call made through knowledge base retrieval or Q&A.

Overdue payments

An account is considered overdue if its available balance is less than zero. Overdue-payment restrictions are isolated by commodity code. When one commodity code has an overdue payment, the services under that commodity code become unavailable and are restored after you settle the overdue amount. Services under other commodity codes remain available and continue to incur charges. For example, when Model Studio reserved capacity in your bill has an overdue payment, the provisioned throughput deployment service under that commodity becomes unavailable, but model calls are not affected.
  • If you still have a free quota or savings plan: These are also isolated by commodity code. They offset only commodity codes that have no overdue payment and cannot be used for a commodity code that is overdue.
  • If you have purchased a Coding Plan or Token Plan: The plan's quota is independent of your account balance and can be used during the overdue period. However, automatic renewal will fail, and you cannot renew the plan after it expires.

Billing for asynchronous tasks when your account is overdue

Models for image and video generation use an asynchronous task mechanism. Task submission, generation completion, and fee settlement may occur at different times. 1. Overdue payment during task execution If your account is in a normal state when you submit a task, the task can be submitted and executed normally. If your account becomes overdue while the task is running, submitted tasks may still continue to execute. For tasks that complete successfully, the system still bills you based on actual usage even if your account is already overdue when the task completes. The related fees are added to your account bill and may further increase the overdue amount. 2. Overdue payment again after recharge Because there is a time lag between asynchronous task execution and fee settlement, some tasks may complete while your account is overdue but their fees have not yet been settled. Therefore, after you recharge your account to settle the overdue amount, you may still receive bills for previously submitted tasks, which can put your account into an overdue state again. 3. Recommendations We recommend that you monitor your account balance and bill changes in a timely manner. In particular, when you submit image and video generation and other asynchronous tasks in batches, keep sufficient account balance to avoid the account becoming overdue again due to delayed settlement of task fees. Note: Fees for asynchronous tasks are subject to the actual billing rules and the final bill. An overdue account does not mean that fees incurred by previously submitted tasks will be waived.

Stop billing

If you no longer use Model Studio, follow the instructions below to stop the related services and prevent further charges.
To proactively control cost limits in pay-as-you-go scenarios, go to Budget Management to set a monthly budget and enable "Stop Service When Budget Reached".
  • Stop model inference: Stop making API calls from your code and stop using the Experience Center in the console to prevent further charges. To prevent accidental calls, you can delete your keys on the API-KEY page.
  • Stop model training: You are not charged when no model training tasks are running.
  • Cancel a Coding Plan subscription: Coding Plan is a monthly subscription product that automatically stops at the end of the subscription period. Mid-term cancellation and refunds are not supported. If you have auto-renewal enabled, disable it on the Coding Plan page.
  • Unsubscribe from Token Plan Team Edition: On the My Subscriptions page of the Token Plan console, you can unsubscribe seats that have not been used, and a refund is issued to the original payment account. If you do not want to renew your subscription, disable auto-renewal.
  • Stop model deployment: Unpublish deployed models. The bill product names and subsequent operations for each billing method are as follows:
    • Pay-as-you-go by model calls: The bill product name is Model Studio Large Model Inference. After you unpublish the deployment, no further call fees are generated for it. You can also delete the API Key to prevent accidental calls.
    • Pay-as-you-go by computing units or model units: The bill product name is Model Studio Model Unit (Pay-as-you-go). Unpublish the deployment to stop duration-based billing.
    • Provisioned throughput, postpaid (hourly): The bill product name is Model Studio Reserved Capacity (Postpaid). Unpublish the deployment to stop hourly billing.
    • Provisioned throughput, prepaid (daily): The bill product name is Model Studio Reserved Capacity (Prepaid). After you unpublish the deployment, go to Refund Management to unsubscribe from the instance. The used portion is settled at a 1.2x coefficient (for more information, see Refund policy), and the remaining amount is refunded.

FAQ

When you view data by model, API Key, workspace, or other dimensions, some values may appear as "-" or be empty. Common causes:
  • Data for a specific dimension is delayed. Right after a call, the value may appear as "-" and change to the actual value after a few minutes or more.
  • An empty API Key usually indicates that the call came from the console.
  • For calls made through Batch Chat, API Key ID-related data is empty.
  • Region information is empty for some models.
  • The invocation method is empty for speech models.
A "-" or empty value does not affect the actual billed amount. To check specific costs, see Bill details.
Cause:
  • Billing latency: Model inference bills are aggregated by the minute and typically appear 2 to 10 minutes after a call. Bills for batch inference, model training, and knowledge base are aggregated hourly. Bill generation may be further delayed during peak hours.
  • Use of a non-commercial model: Models in public preview or invite-only testing do not generate billing records.
Solution: Wait for the billing interval to pass and then check again.
Cause: The same model is billed separately based on the billing type (such as input tokens, output tokens, or cache hits) and the invocation channel (such as an API call or console experience). For example, a single API call to qwen3.6-plus generates two entries: one for "input tokens" and one for "output tokens".Solution: Use the Instance ID field in Billing Details to understand the specifics of each line item.
Cause: The "Billable Item" column on the bill is uniformly labeled "Large Model Text Consumption" and does not show the specific model name.Solution: Check the Instance ID (Billing Granularity) column on the Billing Details page. This field is a semicolon-separated string. The part of the string that immediately follows the workspace ID (such as llm-xxx) is the model name. For example, in 12xxx;llm-xxx; qwen3.6-plus ;context_0-128k_input_token;aicenter;0, the model is qwen3.6-plus.
Go to the Alibaba Cloud Model Studio console, select the target region in the upper-right corner. In the left-side navigation pane, choose Cost and Usage > Model Usage.
No. Alibaba Cloud uses a "reserve and settle monthly" model for pay-as-you-go billing. The system reserves an amount from your available balance to cover usage, and then generates a final bill and deducts the actual cost at the end of the billing cycle (early in the next month).
Reason: Additional features of Model Studio, such as web search, are billed separately (post-paid) based on the number of calls and are invoiced separately from model inference fees. Even if you have not actively used the console recently, if the enable_search parameter is enabled in applications or code that you created in the past, web search fees are still incurred for each call. In addition, your Alibaba Cloud account balance is managed at the account level. If any Alibaba Cloud product under the same account, such as pay-as-you-go ECS or OSS, has unsettled charges, your available balance becomes negative, and Model Studio displays an overdue payment as well, even if you have not used Model Studio itself. Settling the outstanding charges for the affected product restores normal usage of Model Studio.Solution:
  1. In Billing Details, filter for Alibaba Cloud Model Studio and check the Instance ID (Billing Granularity) column to identify the model name and invocation channel that incurred the cost.
  2. Check whether enable_search is enabled in your application code or Model Studio application configuration. If you no longer need web search, set this parameter to false or remove it.
  3. If you have stopped all calls but are still being charged, check if other API keys or applications are still running. You can find and delete unused keys on the API Key page.
Cause:
  • Input tokens accumulate in long context conversations: When the same document is repeatedly included in a long context conversation, the input tokens of each request grow as the context accumulates, so a single call consumes far more tokens than a short conversation. For example, in one investigation, 43 of 47 calls each consumed 580,000 to 600,000 input tokens, and the total input tokens exceeded 25 million, which depleted a balance of CNY 120 in about 20 minutes and resulted in an overdue payment.
  • Alert notifications are sent at a limited frequency: When the available credit of your account falls below the alert threshold, you receive a notification.The notification is sent by email.If you do not check the notification in time, your balance may be depleted before the next alert.
  • Billing latency: Model inference bills are aggregated by the minute. Therefore, you may still receive bills generated by billing latency after the service is suspended, and the overdue amount can keep increasing after the suspension.
Solution:
  • Check the token consumption of individual calls on the Model Usage page to identify requests with high token usage.
  • Configure the available credit alert on the Cost Overview page, and check alert notifications promptly.
  • To stop billing immediately, delete the API keys that you no longer use on the API Key page.
Cause: Model deployment in Model Studio is billed by duration. Billing starts as soon as the model deployment status changes to Running, regardless of API calls. Even if you have not called the model via API, charges continue to accumulate as long as the deployment status is Running. In addition, model inference is billed by token usage — fees are only incurred when API calls are made.Solution:
  1. Go to the Dedicated Deployment page to check whether any deployed models have the status Running. If you no longer need them, take them offline to stop billing.
  2. Delete unused API keys to prevent accidental API calls from generating inference fees (note: deletion is irreversible, proceed with caution). You can manage your keys on the API Key page.
If you suspect your account has been accessed by others and unexpected charges have been incurred, follow these steps to investigate:
  • In Detailed Bill, filter by Model Studio, and check the ApiKeyID in the Instance ID (Billing Granularity) column to identify the API Key generating the charges.
  • Go to the API Key page, review the creation time of each key, and confirm whether it was created by you. The API Key page only shows creation time, not invocation time.
  • Review the call time distribution to identify any abnormal invocation patterns that may not be your own: Go to Model Usage, filter by Model or API Key ID, and switch to the List view to see the invocation time distribution.
  • If unauthorized invocations are found, immediately go to the API Key page to delete the corresponding API Key and regenerate it. Update all legitimate callers to use the new key.
Cause: Model Studio API calls use the pay-as-you-go billing method by default. After you activate Model Studio, you can call the API immediately and pay based on actual usage, without purchasing a resource plan or savings plan. The system automatically charges you based on the token usage and corresponding pricing of the model you call. For detailed pricing information, see Model inference pricing.
Model Studio applies discounted quotas in a fixed offset order: free quota > model-specific savings plan > AI general-purpose savings plan > pay-as-you-go. Each layer is fully consumed before the next one is used. Calls are billed on a pay-as-you-go basis against your account balance only after all discounted quotas are exhausted.The following table compares the options and the rules that apply to each one.

Option

Billing model

Scenarios

Price level

Limits

Key rules

Pay-as-you-go (default)

Post-paid, reserve and settle monthly

Fluctuating usage, or evaluation before you commit

Billed by input and output token usage, with no discounts. The per-token unit price is the highest among all options.

No prepurchase is required, so this option is available at any time. Whether an overdue payment affects model calls depends on the associated commodity code.

No prepurchase is required. The final bill is generated and charged at the beginning of the next month. Whether an overdue payment affects model calls depends on the associated commodity code.

Free quota

Granted quota, offset first

Feature validation and small-scale trials

Free of charge. Granted automatically when you activate Model Studio. The quota cannot be stacked or purchased separately.

The quota amount and validity period are fixed. After the quota is used up, billing automatically falls back to pay-as-you-go. While Stop when free quota is used up (worry-free mode) is turned on, savings plans cannot offset usage.

Turn on Stop when free quota is used up (worry-free mode) in the model settings to suspend calls as soon as the quota runs out, so that no pay-as-you-go charges accrue. While this switch is turned on, no savings plan is applied. Turn the switch off to resume calls and let the savings plan take effect.

Coding Plan

Monthly subscription

A fixed monthly budget for coding scenarios

A fixed monthly cost that does not vary with token usage.

Can be used only for programming tool scenarios. It cannot offset regular API calls or model inference fees incurred in the console. The subscription stops automatically at expiration, and mid-term cancellation and refunds are not supported.

The subscription stops automatically when it expires. Mid-term cancellation and refunds are not supported. If auto-renewal is enabled, disable it on the Coding Plan page.

Token Plan

One-off purchase of credits

Sharing one quota across a team

Credits are purchased per seat as a one-off payment.

Only some models are supported. The quota is independent of your account balance. Seats that have not consumed any usage can be unsubscribed on the My Subscriptions page.

Only some models are supported. You can unsubscribe individually from seats that have not consumed any usage on the My Subscriptions page of the Token Plan console.

AI general-purpose savings plan (recommended)

Commitment to a monthly spend in exchange for tiered discounts

Long-term steady use of large model services

Tiered discounts based on the monthly spend that you commit to: the higher the commitment, the deeper the discount. For the discount of each tier, see Savings plans and resource plans.

Commitment periods of 3, 6, 12, or 24 months are available. The quota is issued monthly and is not carried over to the next period. After the plan takes effect and starts offsetting usage, it generally cannot be unsubscribed and must run until it expires.

Covers all models. After the plan takes effect and starts offsetting usage, it generally cannot be unsubscribed and must run until it expires.

Resource plans are not offered on the international site, which provides savings plans only.For regular API call scenarios, choose the AI general-purpose savings plan first. For programming tool scenarios, choose the Coding Plan first. Choose an option based on these rules: a savings plan for long-term steady usage, a Token Plan when a team shares one quota, and a Coding Plan when you want a fixed monthly spend for coding scenarios. If you are only validating features, use up the free quota first.Model Studio is pay-as-you-go by default and does not grant token quotas in advance. Purchase a savings plan if you need to lock in a quota or reduce costs.For discount tiers, purchase steps, and effective-time rules, see Savings plans and resource plans. To stop billing for any of these options, see Stop billing.
  1. Go to the Billing Details page.
  2. Click the Preferences (gear) icon above the billing table.
  3. In the Customize Columns dialog box, select Commodity Code. Return to the billing table to view the commodity code for each bill.