---
title: Set Entity Data
description: "Play 0x63, server → client."
---

`play` · `0x63` · **clientbound** (server → client)

Updates entity metadata such as pose, custom name, flags, or entity-specific fields. The server sends it after spawning an entity and whenever a tracked value changes. The client applies each metadata entry to the entity.

Sent by the server, read by the client. Listen for it with `client.on("SetEntityData", (data) => …)` on the receiving side.

## Fields

| Field | Type | Notes |
|---|---|---|
| `entityId` | VarInt |  |
| `metadata` | [entityMetadata](/docs/entity-metadata) |  |

## Send it

```ts
import { helpers } from "mc-protocol";

await client.sendPacket("SetEntityData", {
  entityId: 42,
  metadata: helpers.createEntityMetadata("player", {
    customName: { text: "Steve", color: "gold" },
    customNameVisible: true,
    glowing: true,
    health: 20,
  }),
});
```

`metadata` is an array of `{ key, type, value }` entries; the writer appends the `0xff` terminator. See [Entity metadata](/docs/entity-metadata) for the named fields per entity kind and `metadataEntry` for the rest.

Field aliases listed under Notes are accepted as alternative keys when writing.

Source: [`src/Core/Versions/776/Packets/play/clientbound/SetEntityData.ts`](https://github.com/GDLev/mc-protocol/blob/master/src/Core/Versions/776/Packets/play/clientbound/SetEntityData.ts)
