How @@MAX_CONNECTIONS Works in SQL Server

In SQL Server, the @@MAX_CONNECTIONS configuration function returns the maximum number of simultaneous user connections allowed on an instance of SQL Server. The number returned is not necessarily the number currently configured.

No argument is required. You can simply use it in a SELECT statement to return the maximum number of simultaneous user connections allowed on the current server.

Example

Here’s an example to demonstrate.

SELECT @@MAX_CONNECTIONS AS [Max Connections];

Result:

+-------------------+
| Max Connections   |
|-------------------|
| 32767             |
+-------------------+

The return value is integer.

Note that the actual number of user connections allowed also depends on the version of SQL Server that is installed and the limitations of your applications and hardware.