An Elastic IP address (EIP) is a public IPv4 address that you can purchase and manage independently. You can associate an EIP with cloud resources such as Elastic Compute Service (ECS) instances in a Virtual Private Cloud (VPC), an Internet NAT Gateway, or a Server Load Balancer (SLB) instance to enable internet access. EIPs support dynamic association and disassociation for flexible public IP management.
EIP selection
Billing method
|
Billing method |
|||
|
Pay-as-you-go (pay-by-data-transfer) |
Pay-as-you-go (pay-by-bandwidth) |
Subscription (pay-by-bandwidth) |
|
|
Billable item |
|
|
Bandwidth fee |
|
Billing cycle and bill generation time |
|
|
|
|
Scenarios |
Choose the pay-by-data-transfer method if you cannot estimate your data transfer usage. |
|
|
|
Cost optimization |
|
- |
|
Line type
The line type can only be selected when you create an EIP and cannot be changed afterward. Select a line type with caution.
|
Line type |
BGP (Multi-ISP) |
BGP (Multi-ISP) Pro |
|
Description |
Connects to multiple ISP lines and automatically selects the optimal route to provide a fast and stable connection. This line type is supported in all Alibaba Cloud regions. |
Provides an optimized public network route for traffic from outside the Chinese mainland to end users within it (excluding data centers). It uses dedicated ISP lines to reduce latency and improve the quality of international services. |
|
Use cases |
A general-purpose choice suitable for most internet-facing services, ensuring network stability and coverage. |
Optimized for traffic from outside the Chinese mainland to within it, significantly reducing cross-border network latency. |
|
Limitations |
|
|
|
Cost |
Low |
Medium |
Security protection
You can select Anti-DDoS (Enhanced) only when you create an EIP. You cannot switch between the Default and Anti-DDoS (Enhanced) types after the EIP is created. Select a security protection type with caution.
|
Security protection type |
Default |
Anti-DDoS (Enhanced) |
|
Use cases |
No special security requirements. By default, a single EIP provides up to 5 Gbps of basic DDoS protection, which meets basic security needs. |
The default security capabilities may be insufficient for services that require terabit-level protection. |
|
Configuration |
This basic protection is enabled by default for all EIPs. |
You must select this option when you create an EIP. |
|
Limitations |
Supported for EIPs in all regions. |
|
|
Billing changes |
The default security protection is free of charge. |
Security protection fees are incurred. The fees are charged by the Anti-DDoS service. For more information about the billing rules, see Anti-DDoS Origin 2.0 (pay-as-you-go). |
Create an EIP
Console
-
In the EIP console, click Create EIP.
-
Configure the EIP parameters and complete the purchase.
-
Billing Method: The pay-as-you-go billing method is suitable for workloads with variable traffic. The subscription billing method is suitable for long-term, stable workloads. For more information, see Billing method.
If you select the pay-as-you-go billing method, select a metering method for data transfer:
-
When you set the Metering method to Pay-By-Data-Transfer: select Pay-by-CDT. CDT can help you reduce public data transfer costs. Retain the default bandwidth value, which can be adjusted at any time. The peak bandwidth of a pay-by-data-transfer EIP is a reference value and upper limit. It is not a guaranteed performance metric.
-
When you set the Metering method to Pay-By-Bandwidth: You are charged for bandwidth usage. Set the peak bandwidth based on your business requirements.
-
-
Region: Select the same region as your cloud resources. EIPs are region-level resources.
-
Line Type: This parameter is available only in some regions. For guidance, see Line type.
-
Security protection: This parameter is available only for pay-as-you-go BGP (Multi-ISP) EIPs. For guidance, see Security protection.
-
IP address pool: If you have an IP address pool, you can allocate an EIP from the pool.
-
API
Call the AllocateEipAddress operation to create an EIP.
Recover a released public IP
You can request to recover an EIP, or a static public IP address of an ECS or SLB instance that was released from your account within the last seven days.
After a successful request, the system converts the public IP address to a pay-as-you-go EIP that uses the pay-by-data-transfer metering method. The default peak bandwidth is 5 Mbit/s. If your EIP service has been upgraded to CDT-based billing, the data transfer fees for the recovered public IP address are also billed through CDT.
Recovery is not guaranteed. The request may fail if the public IP address has been assigned to another account, locked for security reasons, or reclaimed by the system.
Console
-
In the EIP console, select the region of the EIP and click Apply for Specific EIP.
-
Set Request Type to Apply for Specific EIP. After you configure the parameters, click OK.
-
To request by IP address, enter the public IP address that you previously owned. To retrieve by EIP ID, you can find the historical ID in your historical orders.
-
If the historical EIP was a BGP (Multi-ISP) Pro EIP, set Line Type to BGP (Multi-ISP) Pro. Note that BGP (Multi-ISP) Pro EIPs are supported only in some regions.
-
You can select a specific IP address pool from the drop-down list to request a specific EIP only if you have enabled the IP address pool feature.
-
API
Call the AllocateEipAddressPro operation to request a specific EIP.
Request a contiguous EIP block
You can request a contiguous block of EIPs in the following ways:
-
IP address pool: This feature is not available by default. To use it, contact your business manager.
-
Contiguous EIP group: EIPs in a contiguous EIP group are similar to individual EIPs. They can also be associated with cloud resources for internet access and incur the same charges. However, there are some differences:
-
EIPs in a contiguous EIP group are pay-as-you-go and cannot be converted to the subscription billing method.
-
You cannot release an individual EIP from a contiguous EIP group. You must release all EIPs in the group at the same time.
-
-
Starting from 00:00:00 on August 6, 2024 (UTC+8), the contiguous EIP group feature will no longer be available to new users.
-
If you have used the contiguous EIP group feature before 00:00:00 on August 6, 2024 (UTC+8), you can continue to request and use it. However, we recommend that you migrate your contiguous EIP groups to IP address pools.
Add or remove an EIP from an Internet Shared Bandwidth instance
Internet Shared Bandwidth provides region-level bandwidth sharing and reuse. After you add an EIP to an Internet Shared Bandwidth instance, all EIPs in the instance can share the purchased bandwidth. This helps reduce your overall public bandwidth costs.
-
Only pay-as-you-go EIPs can be added to an Internet Shared Bandwidth instance. After an EIP is added, its peak bandwidth no longer applies, and the Internet Shared Bandwidth instance manages the bandwidth. The EIP no longer incurs data transfer or bandwidth fees, but the public IP retention fee still applies.
-
The EIP and the Internet Shared Bandwidth instance must be in the same region and have the same line type.
-
You can add up to 100 EIPs to a single Internet Shared Bandwidth instance. To add more EIPs, request a quota increase.
Console
Add an EIP to an instance
-
In the EIP console, select the region of the EIP.
-
Find the target EIP. In the Actions column, choose
> Bind EIP Bandwidth Plan. -
Select the Internet Shared Bandwidth instance to which you want to add the EIP and click OK.
Remove an EIP from an instance
When you remove an EIP from an Internet Shared Bandwidth instance, its peak bandwidth and billing method are restored to their previous state. To avoid packet loss due to bandwidth changes, perform this operation during off-peak hours.
-
In the EIP console, select the region of the EIP.
-
Find the target EIP. In the Actions column, choose
> Disassociate from EIP Bandwidth Plan and confirm the action.
API
-
Call the AddCommonBandwidthPackageIp operation to add an EIP to an Internet Shared Bandwidth instance.
-
Call the RemoveCommonBandwidthPackageIp operation to remove an EIP from an Internet Shared Bandwidth instance.
Release an EIP
An unassociated pay-as-you-go EIP still incurs a public IP retention fee. If you no longer need the EIP, release it promptly.
An EIP is an independent public IP address resource and does not store any business data. Releasing an EIP only reclaims the IP address and does not cause data loss on associated cloud resources. Releasing an unassociated EIP does not affect your existing cloud resources or the services that run on them.
-
Only pay-as-you-go EIPs can be released. You cannot release subscription EIPs.
-
You cannot release an EIP that is locked for security reasons.
-
After you release an EIP, billing for the EIP stops. However, you may still receive a final bill for the EIP.
Reason:
-
Pay-by-data-transfer EIPs are billed hourly.
For example, if you release an EIP at 10:30:00, you will receive a bill for the data transfer fees incurred from 10:00:00 to 11:00:00 after 11:00:00.
-
Pay-by-bandwidth EIPs are billed daily.
For example, if you release an EIP on January 1, 2025, you will receive a bill for the bandwidth fees incurred on January 1, 2025 after 00:00 on January 2, 2025.
-
Console
Standard release
To release an EIP, you must first resolve its dependencies: remove the EIP from any Internet Shared Bandwidth instance, disassociate the EIP from any cloud resource, and remove any SNAT or DNAT entries associated with the EIP.
-
In the EIP console, select the region of the EIP.
-
Find the target EIP. In the Actions column, choose
> Release and confirm the action.You cannot release an individual EIP from a contiguous EIP group. To release EIPs in a group, you must release all of them together.
Forced release
When you force-release an EIP, the system first disassociates the EIP from any associated cloud resource, removes it from any Internet Shared Bandwidth instance, and then releases the EIP.
If the EIP is used in an SNAT or DNAT entry of an Internet NAT Gateway, you must first remove the associated entry.
You cannot force-release an EIP that is part of a contiguous EIP group.
-
In the EIP console, select the region of the EIP.
-
Find the target EIP. In the Actions column, choose
> Forceful Release and confirm the action.
API
-
Call the ReleaseEipAddress operation to release a specific EIP.
-
Call the ReleaseEipSegmentAddress operation to release all EIPs in a contiguous EIP group.
Deletion protection
Enable deletion protection for pay-as-you-go EIPs to prevent accidental release. Enable deletion protection for EIPs used in a production environment.
Console
-
In the EIP console, select the region of the EIP. Click the ID of the target EIP.
-
On the EIP details page, enable or disable deletion protection.
API
Call the DeletionProtection operation. Set the Type parameter to EIP and configure the ProtectionEnable parameter to enable or disable deletion protection.
Production guidelines
-
Best practices:
-
Cost optimization:
-
For pay-by-data-transfer EIPs, select Pay-by-CDT. CDT offers benefits such as a free data transfer tier, consolidated billing for IPv4 and IPv6 traffic across multiple cloud services, and tiered pricing. These benefits can help reduce your data transfer costs.
-
For pay-by-bandwidth EIPs, set the peak bandwidth slightly higher than your business requirements. If you use multiple pay-by-bandwidth EIPs, consider using an Internet Shared Bandwidth instance to reduce overall costs through bandwidth reuse.
-
-
Configuration selection: If your service traffic is stable or high, the pay-by-bandwidth method is more cost-effective. If traffic fluctuates or usage is low, the pay-by-data-transfer method offers more flexibility.
-
IP management: For scenarios that require contiguous IPs or specific IP ranges, use the IP address pool feature for unified planning and allocation.
-
-
Risk prevention:
-
Cost risk: An unassociated pay-as-you-go EIP still incurs a public IP retention fee. Associate the EIP with a resource or release it promptly if it is no longer needed.
-
Operational risk: Enable deletion protection for critical EIPs in your production environment to prevent service interruptions caused by accidental release.
-
Quotas
By default, each Alibaba Cloud account can hold up to 20 pay-as-you-go EIPs. You can request a quota increase.
FAQ
When am I charged the public IP retention fee after an EIP is allocated?
-
Pay-as-you-go EIPs:
-
You are charged an EIP configuration fee (public IP address retention fee) as soon as the EIP is created. EIPs allocated from a specified IP address pool are not subject to this fee.
-
When you associate an EIP with a resource, the EIP configuration fee (public IP address retention fee) is waived only if the EIP is directly associated with a VPC-type ECS instance or ECI instance, and your Alibaba Cloud account's (primary account) EIP quota is 2,000 or less.
To avoid unnecessary charges, we recommend that you apply for EIPs only when you need them.
-
-
Subscription EIPs: No EIP configuration fee (public IP address retention fee) is charged.