---
title: "socket.io-client 4.0.0 Breaking Changes on npm | Since.dev"
description: "What each socket.io-client release removed, renamed or changed: 18 breaking changes in 5 versions on npm, each with its source."
canonical_url: https://since.dev/packages/npm/socket.io-client
last_updated: 2026-12-04
---

# socket.io-client breaking changes

socket.io-client 4.0.0 (March 10, 2021) is its newest release with breaking changes, 4 of them. The first: Signature changed Manager. Every breaking API change we have recorded in socket.io-client on npm: 18 breaking changes in 5 versions. Below, its 5 versions with breaking changes, newest first, removals and renames first, each with its source.

Updated December 4, 2026

Latest version `4.8.4`, released September 25, 2026. [Source repository](https://github.com/Automattic/socket.io-client)

Packages on npm run on Node.js. [Node.js end of life dates](https://since.dev/calendar/nodejs.md).

- From [3.0.0](#v-3-0-0) to [4.0.0](#v-4-0-0): 4 breaking changes in 1 version.
- From [2.0.0](#v-2-0-0) to [4.0.0](#v-4-0-0): 17 breaking changes in 4 versions.

## socket.io-client 4.0.0 breaking changes

socket.io-client 4.0.0, released March 10, 2021: 4 breaking changes.

- **Signature changed** `Manager`  

Was class Manager extends Emitter; now class Manager\<ListenEvents extends EventsMap = DefaultEventsMap, EmitEvents extends EventsMap = ListenEvents> extends StrictEventEmitter<{}, {}, ManagerReservedEvents>. [npmjs.com](https://www.npmjs.com/package/socket.io-client/v/4.0.0)
- **Signature changed** `Socket`  

Was class Socket extends Emitter; now class Socket\<ListenEvents extends EventsMap = DefaultEventsMap, EmitEvents extends EventsMap = ListenEvents> extends StrictEventEmitter\<ListenEvents, EmitEvents, SocketReservedEvents>. [npmjs.com](https://www.npmjs.com/package/socket.io-client/v/4.0.0)
- **Signature changed** `Socket.emit`  

Was emit(ev: string, ...args: any\[\]): this; now emit\<Ev extends EventNames\<EmitEvents>>(ev: Ev, ...args: EventParams\<EmitEvents, Ev>): this. [npmjs.com](https://www.npmjs.com/package/socket.io-client/v/4.0.0)
- **Signature changed** `Socket.io`  

Was readonly io: Manager; now readonly io: Manager\<ListenEvents, EmitEvents>. [npmjs.com](https://www.npmjs.com/package/socket.io-client/v/4.0.0)

## socket.io-client 3.0.0 breaking changes

socket.io-client 3.0.0, released November 5, 2020: 11 breaking changes.

- **Removed** `pong`  

Latency must now be measured by emitting a ping with a callback, as shown in the guide. [socket.io](https://socket.io/docs/v4/migrating-from-2-x-to-3-0)
- **Removed** `Socket.binary`  

The Socket#binary() method is gone. Provide your own parser to cover that use case. [github.com](https://github.com/socketio/socket.io-client/releases/tag/3.0.0)
- **Renamed** `error`  

The Socket now emits a connect_error event instead of error, which is no longer a reserved event. Listen for connect_error instead of error. [github.com](https://github.com/socketio/socket.io-client/releases/tag/3.0.0)
- **Renamed** `io`  

The client is now imported as a named export, so default imports of socket.io-client must change. [socket.io](https://socket.io/docs/v4/migrating-from-2-x-to-3-0)
- **Renamed** `query`  

Credentials sent in the CONNECT packet must be passed with the auth option instead of query. [socket.io](https://socket.io/docs/v4/migrating-from-2-x-to-3-0)
- **Behavior changed**  

The client no longer connects to the default namespace automatically. Connect to the namespaces you need explicitly. [github.com](https://github.com/socketio/socket.io-client/releases/tag/3.0.0)
- **Behavior changed**  

Middleware errors are emitted as Error objects instead of before. Update handlers that expect the previous shape. [github.com](https://github.com/socketio/socket.io-client/releases/tag/3.0.0)
- **Behavior changed**  

Events of the Manager are no longer emitted by the Socket. Listen for them on the Manager instance (socket.io) instead. [github.com](https://github.com/socketio/socket.io-client/releases/tag/3.0.0)
- **Behavior changed** `socket.emit`  

emit returns true instead of the socket, so chained emit calls must be split into separate statements. [socket.io](https://socket.io/docs/v4/migrating-from-2-x-to-3-0)
- **Behavior changed** `socket.on`  

Connection state events such as reconnect_attempt must be listened to on socket.io instead of the socket. [socket.io](https://socket.io/docs/v4/migrating-from-2-x-to-3-0)

And 1 more in this version. [Sign up to see every change](https://app.since.dev/login?mode=signup&src=package-page)

## socket.io-client 3.0.0-rc3 breaking changes

socket.io-client 3.0.0-rc3, released November 5, 2020: 1 breaking change.

- **Renamed** `ERROR`  

The ERROR name was renamed to CONNECT_ERROR. Update any references to the new name. [github.com](https://github.com/socketio/socket.io-client/releases/tag/3.0.0-rc3)

## socket.io-client 3.0.0-rc1 breaking changes

socket.io-client 3.0.0-rc1, released November 5, 2020: 1 breaking change.

- **Removed**  

The slim build was removed. Use the development build dist/socket.io.js or the production build dist/socket.io.min.js. [github.com](https://github.com/socketio/socket.io-client/releases/tag/3.0.0-rc1)

## socket.io-client 2.0.0 breaking changes

socket.io-client 2.0.0, released May 8, 2017: 1 breaking change.

- **Behavior changed** `socket.id`  

socket.id values now have the namespace (nsp) prefix added. Code that compares, stores or parses socket.id may need to be updated. [github.com](https://github.com/socketio/socket.io-client/releases/tag/2.0.0)

## Check your code

These are the changes. To see which of them reach your code, [scan a public repository](https://since.dev/scan.md), or have your coding agent call `check_code` with your manifest or lockfile over [MCP](https://since.dev/docs.md#mcp). [The API](https://since.dev/docs.md#api) reads every change in every version. A fix pull request opens for the changes that reach a connected repository. Nothing merges or deploys.

## Put your code on continuous maintenance.

Scan a public repository now, or give your agent one line.

[Scan a repository](https://since.dev/scan.md). Any public GitHub repository. No sign-in.

### Tell your agent what changed since it was trained.

`claude mcp add --transport http since https://api.since.dev/mcp`

[Get an API key](https://app.since.dev/login?mode=signup)

Codex, Cursor and any MCP client use https://api.since.dev/mcp.

---

Every page on this site as Markdown: https://since.dev/sitemap.md. For agents: https://since.dev/llms.txt.
