All Products
Search
Document Center

Function Compute:Billing overview

Last Updated:Jul 14, 2026

This topic describes the billing methods, billable items, unit prices, and billing examples of Function Compute.

Note
  • Before you use Function Compute, you can estimate costs with the pricing calculator.

  • After you use Function Compute, you can view CU usage, resource usage details, and bills on the Resource Usage Details page in the console.

Billing methods

Trial quota

Function Compute provides a trial quota (a CU trial resource plan) for first-time users. If you have not purchased other types of resource plans, any usage beyond the trial quota in each billing cycle is charged on a pay-as-you-go basis.

Pay-as-you-go

You are charged based on the computing resources you actually consume. No charges apply when no resources are consumed.

Resource plans

Function Compute offers CU resource plans in monthly and yearly tiers. After you purchase a resource plan, it offsets your resource consumption first. When the plan is exhausted, billing automatically switches to pay-as-you-go. Resource plans offer lower per-unit pricing, which reduces your overall costs.

Resident resource pools (subscription)

A resident resource pool reserves GPU computing capacity through a monthly subscription. Purchase a pool, assign resident instances to your GPU functions, and get predictable costs with zero cold starts.

Billable items and unit prices

Billable items

Function Compute charges consist of two parts:

  • CU usage: Function Compute uses CU usage as the unified billable item. All resource usage is converted to CU usage by using fixed conversion factors. This topic focuses on how CU usage is metered and billed.

  • Outbound Internet traffic: Outbound Internet traffic is aggregated with other Alibaba Cloud Internet-facing products and billed on the CDT side. For more information, see CDT billing.

Unit prices

CU usage is billed on a monthly tiered basis and calculated independently by region. CU usage in each region is accumulated separately and not merged across regions. For more information, see Billing examples.

Billing cycle

Function Compute bills on an hourly basis. CU usage per function per hour is rounded up, then summed across all functions to produce the total hourly CU usage. If you have a resource plan, it offsets CU usage first. After the plan is exhausted, pay-as-you-go billing applies.

Important

For functions with more than 0 invocations or continuous resource usage within an hour, if the CU cost for that hour is less than USD 0.01, a minimum fee of USD 0.01 applies. If actual usage exceeds this amount, the actual CU cost applies.

CU usage calculation

Note

The CU usage calculation described in this section applies only to elastic instances. Resident instances use a monthly prepaid model. For pricing details, see Resident resource pool pricing.

Calculation formula

All resource usage is converted to CU usage by using fixed conversion factors, then summed to get the total CU usage.

CU usage = Σ(resource usage x CU conversion factor)

Resource usage

Note

Resource usage is the raw measurement of actual resource consumption and is not directly used for billing.

Elastic instances have two states: active and idle. When an instance has no requests to process or no background tasks running, it automatically enters the idle state. The following table describes the scenarios for each state:

Thresholds for determining active and idle state

The system uses the following indicators to determine whether an instance has entered the idle state. All conditions must be met simultaneously:

  • CPU utilization — When the instance's vCPU utilization continuously falls below 0.01 vCPU cores (equivalent to 1% utilization of a single core), the CPU condition for idle state is satisfied.

  • GPU utilization — When the instance's GPU stream processors, decoders, and other components fall below the system threshold, the GPU condition for idle state is satisfied. The threshold varies by GPU series.

  • Network traffic — When the instance's inbound and outbound network traffic continuously falls below 1,000 bytes/second, the network condition for idle state is satisfied.

  • Request processing — The instance is not processing any HTTP requests or background tasks.

Important

An instance transitions from active to idle state only when all of the above conditions are met simultaneously. If vCPU utilization is at or above 0.01 vCPU cores, or if network traffic is at or above 1,000 bytes/second, the instance is billed at the active rate even when there are no active requests.

Elastic instance (active)

Elastic instance (idle)

  • Elastic instances that start automatically to process requests when the minimum instance count is not set (defaults to 0).

  • When the minimum instance count is set to 1 or higher, elastic instances that enter the active state when requests arrive. This applies whether or not idle mode is enabled.

  • Elastic instances that process requests in session affinity scenarios.

  • Elastic instances that process background tasks.

  • Instances with no pending requests when the minimum instance count is set to 1 or higher and idle mode is enabled.

  • Elastic instances during the keep-alive period in session affinity scenarios.

  • Elastic instances not processing any background tasks.

Resource usage = elastic instance (active) usage + elastic instance (idle) usage. When an instance is idle, the system automatically freezes some resources and charges at the minimum keep-alive rate:

  • vCPU resources: No charge.

  • GPU resources: Charged at 11.7% to 23% of the active rate depending on the GPU series:

    Ada.1 series

    Ada.2 series

    Ada.3 series

    Tesla series

    Hopper series

    Hopper.1 series

    Hopper.2 series

    Ampere series

    Blackwell.1 series

    Xpu.1 series

    11.7%

    11.7%

    11.7%

    23%

    13%

    14%

    14%

    16%

    13%

    19%

Setting the minimum instance count to 1 or higher is suitable for latency-sensitive workloads (session affinity, persistent connections, etc.) and background task scenarios. This provides the following benefits:

  • Warm start: Achieves millisecond-level warm starts to keep services running without interruption.

  • Guaranteed delivery: Locks elastic resources to guarantee resource availability.

  • Smart billing for busy and idle periods: Automatically switches to idle billing when there are no requests or background tasks, which further reduces costs.

CU conversion factors

CPU workloads

Billable item

vCPU usage

Memory usage

Function invocations

Disk usage

Unit

CU/(vCPU*second)

CU/(GB*second)

CU/10,000 invocations

CU/(GB*second)

Elastic instance (active) CU conversion factor

1.0

0.15

75

0.05

Elastic instance (idle) CU conversion factor

0

0.15

0

0.05

GPU workloads

Resource/Billable item

Unit

Elastic instance (active) CU conversion factor

Elastic instance (idle) CU conversion factor

Function invocations

CU/10,000 invocations

75

-

vCPU usage

CU/(vCPU*second)

1

0

Memory usage

CU/(GB*second)

0.15

0.10

Disk usage

CU/(GB*second)

0.05

0.05

tesla.1 GPU usage

CU/(GPU memory GB*second)

2.1

0.5

ampere.1 GPU usage

CU/(GPU memory GB*second)

1.8

0.3

ada.1 GPU usage

CU/(GPU memory GB*second)

1.7

0.2

ada.2 GPU usage

CU/(GPU memory GB*second)

1.95

0.23

ada.3 GPU usage

CU/(GPU memory GB*second)

1.95

0.23

blackwell.1 GPU usage

CU/(GPU memory GB*second)

2.1

0.28

hopper.1 GPU usage

CU/(GPU memory GB*second)

2.31

0.315

hopper.2 GPU usage

CU/(GPU memory GB*second)

2.31

0.315

xpu.1 GPU usage

CU/(GPU memory GB*second)

1.2

0.23

Billing examples

You can estimate costs with the pricing calculator or refer to the following examples.

Important

vCPU usage, memory usage, disk usage, and GPU usage are all calculated based on the specifications you configure for your function multiplied by the duration, not the actual resources consumed during execution.

Function Compute pricing calculator

CPU workload billing example

A user creates a CPU function instance with the following specifications: 0.35 vCPU, 512 MB memory, and 512 MB temporary disk. The minimum instance count is set to 1 for the month with a total duration of 50 hours, of which 10 hours are active (processing requests) and 40 hours are idle (no requests). The function is invoked 1,000,000 times. The resource usage, CU usage, and total cost are as follows:

Resource

Usage

Conversion factor

CU usage

Function invocations

1,000,000 invocations

0.0075 CU/invocation

7,500 CU

Elastic instance (active) vCPU usage

vCPU spec x execution duration (seconds) = 0.35 vCPU x 36,000 s = 12,600 vCPU*seconds

1 CU/(vCPU*second)

12,600 CU

Elastic instance (active) memory usage

Memory spec x execution duration (seconds) = 0.5 GB x 36,000 s = 18,000 GB*seconds

0.15 CU/(GB*second)

2,700 CU

Disk usage

Disk spec x total provisioned duration (seconds) = 0.5 GB x 180,000 s = 90,000 GB*seconds

0.05 CU/(GB*second)

0 CU

**Note:** Disk usage up to 10 GB is free.

Elastic instance (idle) vCPU usage

vCPU spec x idle duration (seconds) = 0.35 vCPU x 144,000 s = 50,400 vCPU*seconds

0 CU/(vCPU*second)

**Note:** vCPU resources are free for provisioned minimum instances during idle periods.

0 CU

Elastic instance (idle) memory usage

Memory spec x idle duration (seconds) = 0.5 GB x 144,000 s = 72,000 GB*seconds

0.15 CU/(GB*second)

10,800 CU

Total CU usage

33,600 CU

Total cost = Tier 1 unit price x usage = USD 0.000020/CU x 33,600 CU = USD 0.67

GPU workload billing example (Tesla series)

A user creates a GPU function instance (Tesla series) with the following specifications: 16 GB GPU, 8 vCPU, 32 GB memory, and 512 MB temporary disk. The minimum instance count is set to 1 for the month with a total duration of 50 hours, of which 10 hours are active (processing requests) and 40 hours are idle (no requests). The function is invoked 1,000,000 times. The resource usage, CU usage, and total cost are as follows:

Resource

Usage

Conversion factor

CU usage

Function invocations

1,000,000 invocations

0.0075 CU/invocation

7,500 CU

Elastic instance (active) vCPU usage

vCPU spec x execution duration (seconds) = 8 vCPU x 36,000 s = 288,000 vCPU*seconds

1 CU/(vCPU*second)

288,000 CU

Elastic instance (active) memory usage

Memory spec x execution duration (seconds) = 32 GB x 36,000 s = 1,152,000 GB*seconds

0.15 CU/(GB*second)

172,800 CU

Elastic instance (active) GPU usage

GPU spec x execution duration (seconds) = 16 GB x 36,000 s = 576,000 GB*seconds

2.1 CU/(GB*second)

1,209,600 CU

Disk usage

Disk spec x total provisioned duration (seconds) = 0.5 GB x 180,000 s = 90,000 GB*seconds

0.05 CU/(GB*second)

0 CU

**Note:** Disk usage up to 10 GB is free.

Elastic instance (idle) vCPU usage

vCPU spec x idle duration (seconds) = 8 vCPU x 144,000 s = 1,152,000 vCPU*seconds

0 CU/(vCPU*second)

**Note:** vCPU resources are free for provisioned minimum instances during idle periods.

0 CU

Elastic instance (idle) memory usage

Memory spec x idle duration (seconds) = 32 GB x 144,000 s = 4,608,000 GB*seconds

0.1 CU/(GB*second)

460,800 CU

Elastic instance (idle) GPU usage

GPU spec x idle duration (seconds) = 16 GB x 144,000 s = 2,304,000 GB*seconds

0.5 CU/(GB*second)

1,152,000 CU

Total CU usage

3,290,700 CU

Total cost = Tier 1 unit price x usage = USD 0.000020/CU x 3,290,700 CU = USD 65.81

GPU workload billing example (Blackwell.1 series)

A user creates a GPU function instance (Blackwell.1 series) with the following specifications: 32 GB GPU, 8 vCPU, 64 GB memory, and 512 MB temporary disk. The minimum instance count is set to 1 for the month with a total duration of 50 hours, of which 10 hours are active (processing requests) and 40 hours are idle (no requests). The function is invoked 1,000,000 times. The resource usage, CU usage, and total cost are as follows:

Resource

Usage

Conversion factor

CU usage

Function invocations

1,000,000 invocations

0.0075 CU/invocation

7,500 CU

Elastic instance (active) vCPU usage

vCPU spec x execution duration (seconds) = 8 vCPU x 36,000 s = 288,000 vCPU*seconds

1 CU/(vCPU*second)

288,000 CU

Elastic instance (active) memory usage

Memory spec x execution duration (seconds) = 64 GB x 36,000 s = 2,304,000 GB*seconds

0.15 CU/(GB*second)

345,600 CU

Elastic instance (active) GPU usage

GPU spec x execution duration (seconds) = 32 GB x 36,000 s = 1,152,000 GB*seconds

2.1 CU/(GB*second)

2,419,200 CU

Disk usage

Disk spec x total provisioned duration (seconds) = 0.5 GB x 180,000 s = 90,000 GB*seconds

0.05 CU/(GB*second)

0 CU

**Note:** Disk usage up to 10 GB is free.

Elastic instance (idle) vCPU usage

vCPU spec x idle duration (seconds) = 8 vCPU x 144,000 s = 1,152,000 vCPU*seconds

0 CU/(vCPU*second)

**Note:** vCPU resources are free for provisioned minimum instances during idle periods.

0 CU

Elastic instance (idle) memory usage

Memory spec x idle duration (seconds) = 64 GB x 144,000 s = 9,216,000 GB*seconds

0.10 CU/(GB*second)

921,600 CU

Elastic instance (idle) GPU usage

GPU spec x idle duration (seconds) = 32 GB x 144,000 s = 4,608,000 GB*seconds

0.28 CU/(GB*second)

1,290,240 CU

Total CU usage

5,272,140 CU

Total cost = Tier 1 unit price x usage = USD 0.000020/CU x 5,272,140 CU = USD 105.44

More information

If you use other Alibaba Cloud services within Function Compute, you are also charged for those services in addition to Function Compute fees.

FAQ