WSAEAFNOSUPPORT - 10047 (0x273F)

An address incompatible with the requested protocol was used.

Updated: Feb 21, 2026

Technical Meaning

The WSAEAFNOSUPPORT error code indicates that an address incompatible with the requested protocol was used. This typically occurs when a network operation is attempted using an address or socket type that does not match the required protocol.

Error Details

  • Error Name: WSAEAFNOSUPPORT
  • Numeric Code: 10047 (0x273F)
  • Short Description: An address incompatible with the requested protocol was used.

This error is commonly encountered in network programming, particularly when using sockets. It suggests that there is a mismatch between the type of address or socket being used and the protocol required by the operation.

Usage Context

The WSAEAFNOSUPPORT error can occur in various scenarios where network operations are performed, such as creating a socket, binding an address to a socket, or connecting to a server. It is important to ensure that the correct type of address and socket are used for the specific protocol being employed.

Developer Interpretation

When encountering WSAEAFNOSUPPORT, developers should verify the following:

  • The correct family (e.g., AF_INET for IPv4, AF_INET6 for IPv6) is specified in socket creation functions like socket() or WSASocketW().
  • The address and port are correctly formatted according to the protocol being used.
  • The operation context matches the expected protocol requirements. For example, attempting to use an IPv6 address with a function that expects an IPv4 address will result in this error.

Related Errors

  • WSAEAFNAMETOOLONG: The length of the name is greater than the system's limit for names of that type.
  • WSAEADDRINUSE: A socket operation was attempted on an already used port.
  • WSAEADDRNOTAVAIL: An address could not be found to use as a local or remote endpoint in a connection.

FAQ

Q: What does WSAEAFNOSUPPORT mean?

A: It indicates that the address used is incompatible with the requested protocol. Ensure correct family and address formatting.

Q: How can I resolve this error?

A: Verify the socket family, address format, and operation context to match the required protocol.

Summary

The WSAEAFNOSUPPORT error code highlights a mismatch between the network address or socket type used and the requested protocol. Developers should carefully check their address and socket configurations to ensure they align with the intended protocol for successful network operations.