---
title: "Connect to a PostgreSQL for 1C cluster"
sidebar_label: "Connect to a cluster"
sidebar_position: 8
description: "How to connect to a PostgreSQL for 1C cluster with or without an SSL certificate in the console or from various programming languages"
---

import Formbricks from '@theme/MDXComponents/Formbricks'
import Tabs from '@theme/Tabs'
import TabItem from '@theme/TabItem'
import {TabItemLabel} from '@selectel/docux/components'
import ConnectionAddresses from '@site/i18n/en/docusaurus-plugin-content-docs/current/_partials/managed-databases/common/connection-addresses.mdx'

# Connect to a PostgreSQL for 1C cluster

You can [connect](#connect-to-cluster) to a PostgreSQL for 1C cluster:

* via the psql console client;
* using the pgAdmin graphical database management tool;
* using 1C:Enterprise and other office suites or applications with ODBC or JDBC support;
* using programming code.

Connection with an SSL certificate is unavailable.

When connecting, specify the [port](#connection-ports) and [address](#connection-addresses).

## Connection ports \{#connection-ports}

Use these ports to connect to PostgreSQL for 1C:

* 5432 — the port for direct connection to the PostgreSQL for 1C process;
* 6432 — the port for connection to the master node.

## Connection addresses \{#connection-addresses}

<ConnectionAddresses DatabaseName="PostgreSQL for 1C" slug="postgresql-for-1c" />

## Connect to a cluster \{#connect-to-cluster}

<Tabs queryString="connect-to-cluster">
  <TabItem value="1c" default>
    <TabItemLabel>
      1C:Enterprise
    </TabItemLabel>

    To connect a PostgreSQL for 1C database as a 1C infobase, use the following parameters in the infobase addition form in 1C:Enterprise:

    * **Secure connection** — disabled;
    * **DBMS type** — PostgreSQL;
    * **Database server** — node DNS name or [public IP address](/managed-databases/postgresql-for-1c/public-ip.mdx) (Floating IP);
    * **Database name** — the name of the created database;
    * **Database user** — the database username;
    * **User password** — password.
  </TabItem>

  <TabItem value="bash">
    <TabItemLabel>
      Bash
    </TabItemLabel>

    ```bash
    psql "host=<host> \
          port=<port> \
          dbname=<database_name> \
          user=<database_user_name> \
          sslmode=disable"
    ```

    Specify:

    * `<host>` — node DNS name or [public IP address](/managed-databases/postgresql-for-1c/public-ip.mdx) (Floating IP);
    * `<port>` — [connection port](#connection-ports);
    * `<database_name>` — database name; ;
    * `<database_user_name>` — database username.
  </TabItem>
</Tabs>

<Formbricks />
