Talking AI NPCs with a live face and voice
Give game characters a live face and voice: each NPC's personality and the player's quest state are set by your server, NPCs act on the game through your own functions, and conversations run in browser and React Native games.
Yes, for games that run in a browser or in React Native. Realtime Avatar turns one portrait into a character that holds a live voice and video conversation with the player: the player speaks, the NPC listens, answers in its own voice, and its face moves with the words. The SDK is TypeScript, with React and React Native entry points. There is no Unity or Unreal plugin, so a game built in one of those engines has no supported client today.
One portrait per face, one brief per conversation
Each NPC with its own face is one avatar, created from a single portrait. The platform generates the idle loop that plays while the NPC is waiting and the reaction it plays when the player starts talking. Plans include Starter 5, Developer 25 and Studio 100 avatars. Creating a character is billed separately from talking to it: $3 per avatar beyond the number your plan includes, its generated resting loop included.
The personality is not baked into the avatar. instructions is set by your server for each conversation, so one face can be a blacksmith in one quest and a smuggler in another, and a per-call voice override changes how it sounds. Keep the lore, the speaking style and what the NPC must never reveal in those instructions.
Quest state goes in, game actions come out
Your server knows what the player has done, so it says so when the conversation starts: context replays up to 32 prior messages, such as earlier dialogue with this NPC or a system note that the player already returned the stolen ledger. During the call, with clientTools: true granted at mint, the NPC can call functions you register in the game client, for example get_quest_state, give_item or open_shop. They execute in your code, so the game's rules decide whether an item can be given, not the model. Each must return within 2.5 seconds, which suits reads of local game state and short writes.
After the conversation, the transcript webhook delivers both sides of the dialogue and the tool calls the model acted on, signed, with the metadata you set (a player id and an NPC id). That is how a later scene can remember what was said: your server stores what matters and passes it back as context next time. A new session does not inherit memory on its own.
A face, or a voice over your own art
AvatarCall renders the NPC's face as live video over LiveKit WebRTC. Pass mode="voice" for an audio-only conversation: no video track is requested, so nothing renders or decodes, which suits an NPC your game already draws. Every call is full duplex, so a player can interrupt the NPC mid-line and it stops.
import { AvatarCall, createProxyClient } from "realtime-avatar/react";
const client = createProxyClient({ proxyUrl: "/api/realtime-avatar" });
<AvatarCall client={client} avatarId={avatarId} />
// Audio only: no video track is requested, so nothing renders and
// nothing decodes.
<AvatarCall client={client} avatarId={avatarId} mode="voice" />Concurrency is the number to plan for
Every player in a conversation is one concurrent stream, and plans cap them at Starter 3, Developer 10 and Studio 20; Scale is quoted for more. A call started at the cap is refused with concurrency_limit_reached, which is not a queue position, and sessions that are still starting count too. Treat NPC conversations as short scenes the player opens and closes, end the session when the player walks away, and set maxSeconds so an abandoned conversation cannot hold a stream.
What it costs for a launch month
Assume 1,500 NPC conversations a month at 2 minutes each: 3,000 minutes on air, with up to 15 running at the same time. Under those assumptions the lowest-cost published plan that fits is Studio at $119 a month, about $0.08 per NPC conversation. Starter (3 simultaneous streams) and Developer (10 simultaneous streams) cannot hold that peak, so they are not listed.
| Plan | Subscription | Included minutes | Overage | Estimated total |
|---|---|---|---|---|
| Studio | $119 | 3,000 | $0 | $119 |
The estimate is the monthly subscription plus any minutes beyond the plan's included minutes at its published overage rate. Speech recognition, the language model, the voice and the rendered video are all inside a live minute. It excludes avatar creation, taxes, annual discounts and your own hosting. Try your own volume in the cost calculator, or see every plan on the pricing page.
Build it
There is no hosted NPC demo yet. Read Creating an avatar for portraits and idle loops, Tool calling for the tool plane, and React and React Native to embed the call.
Create a free Sandbox workspace to try it: it includes 480 credits once per account, which is 8 realtime minutes if you spend them all on air, and you can start on an example avatar before making your own. The quickstart takes you from a key to a live call.