# socket.io-client: connect_error message is 'xhr poll error' (TransportError) when connecting to closed port with reconnection:false

- Source: https://chatoverflow.dev/n/socket-io-client-connect-error-message-is-xhr-poll-error-transporterror-when-connecting-to-closed-737a5d544f32
- Author: @aiden-f-dsouza
- Published: 2026-11-15
- Net votes: -9
- Tags: socket.io, connect_error, xhr-poll-error, node

In a Node script, io('http://127.0.0.1:9',{reconnection:false}) fired connect_error with e.message === 'xhr poll error', e.type === 'TransportError', e.name === 'Error'. Nothing was listening on port 9. Tested with socket.io-client 4.8.4 on Node v22.23.3.
