ElevenAgents React SDK v1.0
- Written by
- Kræn Hansen
- Published
ListenListen to this article
Version 1.0.0 of the ElevenAgents JavaScript and React SDK is now available. This release is a ground-up re-architecture of the @elevenlabs/client, @elevenlabs/react, and @elevenlabs/react-native packages, focused on render performance, a unified API across web and React Native, and a stable public API. It is a breaking change, but the familiar useConversation hook is preserved, and a coding agent skill is available to automate the upgrade.
Why a new major version
Three problems drove this release.
Different APIs on web and React Native
React and React Native had different APIs, different feature sets, and different configuration options. Code and knowledge didn't transfer between platforms, and AI coding tools frequently suggested APIs that only existed on one platform. React Native also lacked WebSocket connection mode entirely.
Internally, this happened because the React Native SDK wrapped a third-party React Native SDK instead of building on @elevenlabs/client. Features and fixes had to ship twice, and the two platforms drifted further apart with each release.
Poor render performance
Any state change (status, mode, mute, volume) re-rendered every component that consumed conversation state. There was no way to subscribe to just the slice you needed. If your component only cared about connection status, it still re-rendered when the mute state changed.
This was because the SDK used a single context provider spanning all conversation state, with only coarse hooks and callbacks passed through options objects.
Fragile upgrades
Upgrading the SDK risked breaking your code. Internal classes like Input, Output, and Connection were part of the public API, and developers relied on raw browser primitives like conversation.output.gain.gain.value for volume and conversation.input.analyser for audio visualization. Any internal change could break these access patterns.
On our side, an inheritance-based class hierarchy made it difficult to fix this incrementally, so a clean break was needed.
What's new
One API across platforms
@elevenlabs/react-native now re-exports @elevenlabs/react with a thin platform strategy layer: around 40 lines of code, down from over a thousand. The same ConversationProvider, the same hooks, the same methods. Code written for the web works on React Native with only an import path change, knowledge transfers directly between platforms, and AI coding tools no longer hallucinate platform-specific APIs.
Granular hooks for render performance
Six new hooks each subscribe to an individual slice of conversation state. Components only re-render when the data they consume changes.
A status indicator that previously re-rendered on every state change now only re-renders when the connection status itself changes:
useConversation is still there
The familiar useConversation hook still exists and returns the same shape of data: status, mode, mute state, and all control methods. It is a convenience wrapper over the granular hooks described above. Existing users can migrate to ConversationProvider + useConversation as a first step, then adopt granular hooks incrementally where render performance matters.
Dynamic client tools
useConversationClientTool lets React components register tools that the agent can invoke. Tools are tied to component lifecycle: they register on mount, unregister on unmount, and always use the latest closure value.
This is useful when a tool's handler needs access to component state or props that aren't available at the provider level.
Stable API surface
Internal classes (Input, Output, wake lock) are now private. The public API exposes documented methods instead of raw browser primitives:
setVolume({ volume })replacesconversation.output.gain.gain.value = vgetInputByteFrequencyData()replacesconversation.input.analyser.getByteFrequencyData()setMicMuted(true)replacesconversation.input.setMuted(true)
This means the underlying audio implementation can be replaced (for example, swapping transport layers) without breaking user code.
Controlled state
ConversationProvider accepts isMuted and onMutedChange props for external state management. This is useful for persisting mute state across sessions or synchronizing it with application-level state.
When these props are omitted, mute state is managed internally as before.
Smart connection type inference
Voice conversations now default to WebRTC and text-only conversations default to WebSocket. There is no need to set connectionType manually in most cases. If you need a specific connection type, you can still pass it explicitly.
Upgrading
This is a breaking change that requires updates to existing integrations. The key changes at a glance:
Conversationis now a namespace object and type alias, not a class.instanceofchecks and subclassing no longer work.useConversationrequires aConversationProviderancestor.InputandOutputclasses are replaced by documented methods on the conversation instance.- On React Native,
ElevenLabsProvideris replaced byConversationProviderfrom@elevenlabs/react-native.
For the full list of breaking changes, see the changelog.
Automated migration with your coding agent
A dedicated skill is available to automate the upgrade. The skill reads your existing integration, applies the necessary API changes, and updates imports. It handles the mechanical work of migrating to ConversationProvider, replacing removed class references, and updating method calls.
The skill is particularly useful for larger codebases where the migration touches multiple files.
Updated documentation
The SDK documentation has been updated to reflect the new API:
Getting started
Install the package for your platform:
@elevenlabs/react re-exports everything from @elevenlabs/client, so you do not need to install both.
Wrap your app in a ConversationProvider, use the hooks to start a session, and refer to the SDK documentation for the full API reference.
And as we mentioned in the intro, a coding agent skill is available to automate the upgrade:
Feedback
If you encounter issues or have suggestions, open an issue on GitHub. The SDK is actively maintained and we review every report.




