Common SQL Errors

SQL Error 26 – Error Locating Server/Instance Specified Explained and Fixed

June 25, 2025

The client cannot locate the specified SQL Server instance, preventing the connection.

Sign up for the latest in common SQL errors from the Galaxy Team!
Welcome to the Galaxy, Guardian!
You'll be receiving a confirmation email

Follow us on twitter :)
Oops! Something went wrong while submitting the form.

What does SQL Error 26 – Error Locating Server/Instance Specified mean and how do I fix it?

SQL Error 26 – “Error Locating Server/Instance Specified” means the client can’t find the SQL Server instance named in your connection string. Enable SQL Browser, verify instance name, open port 1433/UDP 1434 in the firewall, and allow TCP/IP in SQL Server Configuration Manager to resolve the error.

Error Highlights

Typical Error Message

A network-related or instance-specific error occurred while establishing a connection to SQL Server. Error 26 – Error Locating Server/Instance Specified.

Error Type

Connection Error

Language

Microsoft SQL Server

Symbol

Error Code

SQL State

Explanation

Table of Contents

What Is SQL Error 26 – Error Locating Server/Instance Specified?

SQL Error 26 originates from the SQL Server Native Client when it cannot discover the server name or named instance provided in a connection string. The client sends a UDP broadcast on port 1434 to the SQL Browser service, expecting to receive the TCP port of the instance.

If no reply arrives or the name mapping fails, the driver aborts the connection and raises Error 26 before authentication is attempted.

The message is platform-agnostic and appears in SSMS, .NET apps, Docker containers, sqlcmd, Azure DevOps pipelines, and any tool using ODBC, Ole DB, or SqlClient.

Because discovery fails early, troubleshooting focuses on network configuration, instance visibility, and firewall rules—not login credentials.

What Causes This Error?

Error 26 is commonly triggered when SQL Browser is stopped or blocked, TCP/IP protocol is disabled, the instance name is misspelled, dynamic ports are not known, or a firewall discards UDP 1434 or the instance’s TCP port.

Client/server version mismatches and VPN or container networks that lack UDP broadcast support also cause discovery failures.

How to Fix SQL Error 26

Start by confirming the instance name in the connection string: “Server=MyHost\\MyInstance”. Use SQL Server Configuration Manager to verify the instance listens on TCP and note its port. Ensure the SQL Browser service is running. Add inbound rules for UDP 1434 and the instance’s TCP port on Windows Firewall or cloud security groups.

Finally, test connectivity with sqlcmd using “-S tcp:Host,Port” to bypass discovery.

Common Scenarios and Solutions

Local development machines often disable SQL Browser to reduce surface area. Re-enable it or specify “tcp:.” with explicit port. In Docker Compose, publish UDP 1434 and the TCP port so the host network can reach the containerized SQL Server. On corporate VPNs, multicast/UDP is blocked; switch to explicit port syntax or host file mapping.

In Azure SQL Managed Instance, use the fully qualified DNS name; SQL Browser is not exposed.

Best Practices to Avoid This Error

Favor explicit TCP syntax “tcp:server,port” in production connection strings to eliminate dependency on SQL Browser. Automate firewall rules in IaC templates. Monitor the SQL Browser Windows-Service and alert on stoppage. Use predictable static ports instead of dynamic ports where compliance allows.

Store connection parameters centrally in Galaxy Collections so engineers reuse validated strings.

How Galaxy Helps

Galaxy’s connection manager validates instance names during setup and surfaces Error 26 diagnostics inline. Shared, endorsed connection profiles prevent typos, while the AI copilot suggests the correct “tcp:host,port” syntax. Teams quickly troubleshoot via Galaxy’s run history and collaboration features, eliminating guesswork and downtime.

.

Common Causes

SQL Browser Service Stopped

The UDP listener that maps instance names to ports is not running, so discovery fails immediately and Error 26 appears.

UDP 1434 Blocked by Firewall

Even if SQL Browser runs, a local or network firewall that blocks UDP 1434 prevents the client from receiving the port information.

TCP/IP Disabled for the Instance

If TCP/IP protocol is disabled in SQL Server Network Configuration, only shared memory works, causing remote clients to raise Error 26.

Incorrect Server or Instance Name

Typos, missing backslashes, or using the wrong host name result in the client querying a non-existent instance and triggering the error.

Dynamic Port Unknown

Instances using dynamic ports may pick a port not yet opened in the firewall, making the returned port unreachable and raising Error 26.

.

Related Errors

SQL Error 40 – Could Not Open a Connection

Raised when the client finds the server but the TCP handshake or login packet fails.

Often follows Error 26 if discovery succeeds but connection still blocked.

SQL Error 53 – Network Path Not Found

Thrown when the host name cannot be resolved via DNS or NetBIOS, unlike Error 26 which deals with instance discovery.

SQL Error 18456 – Login Failed for User

Occurs after the client successfully reaches the server, but authentication fails; not a discovery issue.

Provider: Named Pipes Error 40

Similar symptom but specific to Named Pipes protocol when \\Server\pipe\sql\query cannot be reached.

.

FAQs

Does Error 26 mean SQL Server is down?

No. Error 26 only indicates the client cannot find the instance. The server may be running but unreachable due to network or configuration issues.

Is opening UDP 1434 a security risk?

UDP 1434 exposes instance port numbers. Mitigate risk by using explicit ports and disabling SQL Browser on public networks.

Can I fix Error 26 without restarting SQL Server?

Yes. Starting the SQL Browser service or opening firewall ports usually resolves the error without touching the database engine.

Why does Error 26 appear only on VPN?

Many VPNs block UDP broadcasts. Use the “tcp:server,port” format or configure split tunneling to allow UDP 1434.

Start Querying with the Modern SQL Editor Today!
Welcome to the Galaxy, Guardian!
You'll be receiving a confirmation email

Follow us on twitter :)
Oops! Something went wrong while submitting the form.

Check out some other errors

Trusted by top engineers on high-velocity teams
Aryeo Logo
Assort Health
Curri
Rubie Logo
Bauhealth Logo
Truvideo Logo