> For the complete documentation index, see [llms.txt](https://docs.digitalsamba.com/reference/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.digitalsamba.com/reference/sdk/events/captionsfontsizechanged.md).

# captionsFontSizeChanged

When the user changes the captions font size from the settings inside the room, then the **captionsFontSizeChanged** event will be emitted.

{% hint style="info" %}
You can also change the captions font size programmatically through the SDK. Use the [configureCaptions](/reference/sdk/methods/configurecaptions.md) method to achieve that.
{% endhint %}

#### Sample payload

```json
{
  "type": "captionsFontSizeChanged",
  "data": {
    "fontSize": "large"
  }
}
```

#### Sample subscription code

```javascript
sambaFrame.on('captionsFontSizeChanged', (event) => {
  const data = event.data;
  //Possible values for "fontSize" field are "small", "medium" and "large"
  console.log('Captions font size has been changed to', data.fontSize);
});
```
