How to link winsock.lib? April 28, 2023 by Tarik The lib file of winsock is “ws_32.lib” (or “ws2_32.lib”), please make sure you’ve added it.