To connect to a PolarDB cluster, enter an endpoint of the PolarDB cluster. PolarDB supports cluster endpoints and primary endpoints. For each type of endpoints, you can apply for an internal endpoint or a public endpoint to connect to the cluster. This topic describes how to view or apply for an endpoint in the PolarDB console.
Cluster endpoint and primary endpoint

Endpoint | Description | Network type |
---|---|---|
Cluster endpoint (recommended) |
Note A PolarDB cluster provides a default cluster endpoint. You can create one or more custom cluster endpoints based on your needs. When you create a custom cluster endpoint, you can specify the nodes that can be connected by using the endpoint and set the read/write mode. For more information, see Create and modify a custom cluster endpoint. |
|
Primary endpoint |
|
Internal endpoint and public endpoint
Network type | Description | Scenario |
---|---|---|
Internal network |
| Examples:
|
Internet |
| Example: You can connect to your PolarDB cluster through a public endpoint to maintain databases. |
View endpoints and ports
- Log on to the PolarDB console.
- In the upper-left corner of the console, select the region in which the cluster that you want to manage is deployed.
- Find the cluster and click the cluster ID.
- In the Endpoints section of the Overview page, view the endpoint and port information by using one of the following methods:
- Method 1
In the upper-right corner of the Endpoints section, click the
icon to switch views to view the endpoint and port information.
- Method 2
Click Modify on the right of the cluster endpoint. In the dialog box that appears, view Network Information that includes the endpoint and the port number.
Note- If you use a domain name to connect to a database, you can click Bind Private Domain to bind the domain name to an internal endpoint. This allows you to retain the original database domain name after the database is migrated to the cloud. You can bind private domain names only to VPC-facing Endpoint endpoints. For more information, see Private domain names.
- By default, a PolarDB for PostgreSQL(Compatible with Oracle) cluster includes port 1521 in its endpoint. You cannot modify the port.
- Method 1
Apply for an endpoint
- Log on to the PolarDB console.
- In the upper-left corner of the console, select the region in which the cluster that you want to manage is deployed.
- Find the cluster and click the cluster ID.
- In the Endpoints section of the Overview page, view the endpoint and port information by using one of the following methods:
- Click Apply.
- Method 1
- In the upper-right corner of the Endpoints section, click the
icon to switch views.
- Click Apply.
- In the upper-right corner of the Endpoints section, click the
- Method 2
- Click Modify on the right of the cluster endpoint.
- In the Network Information section of the dialog box that appears, click Apply.
Note- You can apply only for Public-facing Endpoint endpoints.
- When you create a cluster, a default VPC-facing Endpoint endpoint is generated. You do not need to apply for this endpoint.
- Method 1
- In the dialog box that appears, specify a prefix for the endpoint and click OK. Note The prefix of the endpoint must meet the following requirements:
- The prefix must be 6 to 30 characters in length, and can contain lowercase letters, digits, and hyphens (-).
- The prefix must start with a letter and end with a digit or a letter.
What to do next
Related API operations
API | Description |
---|---|
DescribeDBClusterEndpoints | Queries the endpoint of a specified PolarDB cluster. |
CreateDBEndpointAddress | Creates a public endpoint for a specified PolarDB cluster. |
ModifyDBEndpointAddress | Modifies the default endpoint of a specified PolarDB cluster. |
DeleteDBEndpointAddress | Deletes a cluster endpoint of a specified PolarDB cluster. |