WSAEREFUSED - 10112 (0x2780)

A database query failed because it was actively refused.

Updated: Feb 21, 2026

Technical Meaning

The error code WSAEREFUSED with the numeric value 10112 and hexadecimal representation 0x2780 is returned by the Windows Sockets API when a network operation fails due to an active refusal. This typically indicates that the requested service or resource is not available at the specified endpoint.

Error Details

The WSAEREFUSED error code signifies that the system attempted to establish a connection, send data, or perform another network-related operation but was refused by the remote host. This can occur for various reasons such as incorrect service name, port unavailability, or the server being down.

Usage Context

This error is commonly encountered in applications using the Windows Sockets API (Winsock) to communicate over a network. It may be returned when attempting to connect to a server, send data, or perform other operations that require active communication with another host.

Developer Interpretation

When encountering WSAEREFUSED, developers should consider several factors:

  • Service Name: Ensure the service name used in the connection attempt is correct and matches the service being offered by the remote host.
  • Port Availability: Verify that the port number specified for communication is available on the remote host. Ports may be blocked or already in use by other applications.
  • Server Status: Confirm that the server to which the application is attempting to connect is operational and accepting connections.

Related Errors

  • WSAECONNREFUSED (10061, 0x2745): Connection refused. This error typically occurs when a connection attempt fails because the remote host actively refuses it.
  • WSAEADDRNOTAVAIL (10049, 0x2801): Address not available. This error may be returned if an invalid address is specified in the connection request.

FAQ

Q: What does WSAEREFUSED mean?

A: The WSAEREFUSED error indicates that a network operation was refused by the remote host, typically due to incorrect service name, port unavailability, or server status issues.

Q: How can I resolve this issue?

A: Review the connection parameters and ensure they are correct. Check the status of the remote server and verify that the specified service and port are available.

Summary

The WSAEREFUSED error code is a generic indication that a network operation was refused by the remote host. Developers should focus on validating connection parameters, ensuring the remote server is operational, and confirming that the correct services and ports are in use.