---
title: "External access"
url: https://docs.corefinity.com/guides/sites/database/external-access
type: guide
last_updated: 2026-11-13
feature: database-external-access
---
# External access

Give a system outside the site, such as an order system or a reporting tool, its own login to an environment's database from addresses you choose.

## Before you start

- The organisation that pays for the site turns external access on and off. A user of an agency that manages the site sees **Ask your account owner** instead.
- External access adds a monthly charge for a dedicated IP address. The dialog shows the price before you accept it.
- Allowed addresses are public IPv4 addresses or ranges from `/32` to `/28`, up to 10. An environment can hold 5 external users.

## Turn on external access

1. **Open Database**

   Go to **Managed Websites**, choose the site, then **Database** under **Site settings**. On the **External database access** card, choose **Turn on…**.

   _Screenshot: The External database access card reading Off, with the Turn on… button ringed and the line A fixed address and host name on port 3306, up to 10 allowed addresses and 5 users._

2. **Enter the first allowed address**

   Enter the **First allowed address** and a **Label** saying whose it is. Tick the box that accepts the monthly charge, then choose the **Turn on** button.

   _Screenshot: The Turn on external database access dialog: the First allowed address field, the label Order system (ERP), the dedicated IP address charge for each month and the tick box that accepts it._

The card reads **Turning on**, then **On**, usually within a few minutes. If it reads **Tonight**, it is ready in that night's [maintenance window](/guides/sites/site-settings/maintenance-window).

## Add an external user and connect

1. **Add the user**

   On **Database users**, choose **Add user** and the kind **External**: the rest is as for any [database user](/guides/sites/database/database-users). Under **Limits and TLS (optional)**, cap its connections and query time, and tick **Require TLS (encrypted, not CA-verified)**.

   _Screenshot: The Database users card with reporting, an internal read-only user, and erp_sync, an external read-write user that connects from 2 allowed addresses, limited to 10 connections and 300 seconds, with TLS required._

2. **Connect the outside system**

   Give the system the **Host**, **Port** and **Database** from the **External database access** card, with the user's name and password. Use the host name, not the **Fixed address**: the host name stays the same if the address changes.

   _Screenshot: The External database access card reading On: the host name, port 3306, the database, the fixed address, TLS optional, and two allowed addresses labelled Reporting office and Order system (ERP), each with Rename and Remove._

## Change the allowed addresses

Under **Allowed addresses**, choose **Add an IP address**, or **Rename** or **Remove** on a row. A change applies in about a minute.

The last address cannot be removed while external access is on.

## Turn off external access

1. **Choose Turn off…**

   Choose **Turn off…**, type the environment's name, then confirm.

   > **Warning:** Outside systems lose access straight away and the external users are deleted. The fixed address cannot be got back: turning external access on again gives a new address under the same host name.

The charge stops from that moment.

## Automate this

**API:** [Turn external database access on](https://docs.corefinity.com/api/reference/database/enable-site-external-database.md), scope `write`

```bash
curl -X POST https://manage.corefinity.com/api/corestack/sites/1042/external-db/enable \
  -H "Authorization: Bearer $COREFINITY_TOKEN" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{
    "confirm_cost": true,
    "sources": [
      {
        "cidr": "198.51.100.64/29",
        "label": "Order system"
      }
    ]
  }'
```

**MCP:** [`corestack_external_db_enable`](https://docs.corefinity.com/mcp/tools/corestack_external_db_enable.md), scope `write`

```json
{
  "name": "corestack_external_db_enable",
  "arguments": {
    "site_id": 4211,
    "sources": [
      {
        "cidr": "203.0.113.10/32",
        "label": "Order system"
      }
    ],
    "confirm_cost": true
  }
}
```

**Control Panel:** Managed Websites › your site › Site settings › Database ([https://manage.corefinity.com/go/database](https://manage.corefinity.com/go/database))

## Related

- [Database users](/guides/sites/database/database-users): Add, rotate and delete database logins.
- [Firewall](/guides/sites/access-and-security/firewall): Allow an IP address to reach a site.
- [Maintenance window](/guides/sites/site-settings/maintenance-window): Choose when routine maintenance happens on a site.
