All Products
Search
Document Center

PolarDB:View or apply for an endpoint

Last Updated:Mar 28, 2026

To connect to a PolarDB cluster, you need its endpoint and port. Each cluster has a private endpoint by default. Apply for a public endpoint only when connecting from outside a virtual private cloud (VPC), such as for local development or maintenance — private endpoints deliver better performance and are recommended for production workloads.

Endpoint types

PolarDB provides three endpoint types. The cluster endpoint handles most workloads and is recommended for general use.

image
Endpoint typeDescriptionSupported network typesCustom domain name
Cluster endpoint (recommended)The default cluster endpoint. All traffic is routed through PolarProxy, which automatically splits read/write traffic — writes go to the primary node, reads go to read-only nodes.Private, PublicSupported (Private only)
Primary endpointOne per cluster. Always connects to the primary node and supports both read and write operations. Automatically switches to the new primary node if failover occurs.Private, PublicSupported (Private only)
Custom endpointUp to five custom endpoints per cluster. Traffic is routed through PolarProxy. Configure the read/write mode, load balancing policy, and the read-only nodes that handle requests.PrivateSupported (Private only)
Associating a custom endpoint with a single node is not recommended for production environments. If that node fails, the endpoint may be unavailable for up to 1 hour.

Private and public endpoints

Network typeDescriptionWhen to use
PrivateOptimal performance. A default private endpoint is created when you create a cluster. You can modify it but cannot delete it.ECS instances in the same VPC, or tools like Data Management (DMS) that support VPC access
PublicApply for or delete as needed. Does not guarantee the same performance as a private endpoint.Connecting from outside a VPC, such as for local development or maintenance

View endpoints and ports

  1. Log on to the PolarDB console. In the left-side navigation pane, click Clusters. In the upper-left corner, select the region of the cluster. In the cluster list, find the cluster and click its ID to go to its Basic Information page.

  2. In the Database Connections section, move your cursor over the desired endpoint. The Network Information dialog appears, showing the endpoint address and port number.

    image

To retain an existing domain name after migrating a cluster to the cloud, click image > Bind Private Domain Name. Only Private endpoints support binding private domain names.

Apply for a public endpoint

Private endpoints are created automatically when you create a cluster or a custom endpoint — no action is required. Apply for a Public endpoint when you need to connect from outside a VPC.

  1. Log on to the PolarDB console. In the left-side navigation pane, click Clusters. In the upper-left corner, select the region of the cluster. In the cluster list, find the cluster and click its ID to go to its Basic Information page.

  2. In the Database Connections section, find the desired endpoint and click Apply.

    image

  3. In the dialog box, set the endpoint prefix and click OK. The endpoint prefix must meet the following requirements:

    • 6 to 40 characters in length

    • Lowercase letters, digits, and hyphens (-) only

    • Starts with a letter and ends with a letter or digit

What's next

Connect to the cluster

API reference

OperationDescription
CreateDBEndpointAddressCreates a public endpoint for the primary endpoint, the default cluster endpoint, or a custom cluster endpoint.
DescribeDBClusterEndpointsQueries the endpoints of a PolarDB cluster.