> ## Documentation Index
> Fetch the complete documentation index at: https://docs.withterminal.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Duplicate Connections

> Learn what duplicate connections are and best practices for handling them.

## What are duplicate connections?

Each connection in Terminal is a link to an underlying telematics provider account. When an end user goes through the [Link Flow](/link-component), it's possible to create more than one connection to the same provider account.

Whether Terminal reuses an existing connection or creates a new one depends on your application's **Dedupe Connections** setting.

## Dedupe Connections setting

Configure this in the [Terminal Dashboard](https://dashboard.withterminal.com/settings) under **Settings > General > Dedupe Connections**.

Enabled is the default for production applications.

### Enabled

When deduplication is enabled, Terminal checks for an existing connection to the same provider account before creating a new one. A match requires:

* The same provider account (`sourceId`)
* The same [External ID](/terminal-platform/custom-identifiers), or no External ID on either the existing or incoming connection

If a match is found, Terminal **updates the existing connection** instead of creating a new one. Credentials, tags, and other metadata from the Link Flow are merged into that connection.

If no match is found — for example, because a different External ID was passed — Terminal creates a new connection to the same provider account.

### Disabled

When deduplication is disabled, Terminal **always creates a new connection** when a user completes the Link Flow, even if that provider account is already connected.

Use this when you intentionally want multiple connections to the same provider account — for example, to represent different business contexts, customers, or internal identifiers as separate connections.

External IDs do not prevent duplicate connections when deduplication is disabled.

## How External IDs impact duplicate connections

External IDs are one of the ways to associate [Custom Identifiers](/terminal-platform/custom-identifiers) with a connection. External IDs are intended to be **your system's** unique identifier for the connection.

When **Dedupe Connections** is enabled, passing a different External ID into the [Link Flow](/link-component) than the one on an existing connection causes Terminal to create a second connection to the same provider account. For this reason, we recommend using a consistent External ID from your system when initiating the [Link Flow](/link-component).

This lets you intentionally create duplicate connections when you need multiple connections to the same provider account while deduplication is otherwise enabled.
