> ## Documentation Index
> Fetch the complete documentation index at: https://developer.watson-orchestrate.ibm.com/llms.txt
> Use this file to discover all available pages before exploring further.

# doAutoScroll()

Automatically scrolls the chat view to the latest message in the conversation.

## Syntax

```javascript theme={null}
instance.doAutoScroll();
```

## Parameters

<ParamField path="None" />

## Returns

<ResponseField name="void">
  Returns a `void` operator.
</ResponseField>

## Examples

The following example scrolls to the latest message after receiving a response:

```javascript theme={null}
// Scroll to the latest message after receiving a response
instance.on('receive', (event, instance) => {
    instance.doAutoScroll();
});
```

<Card title="Do you need practical examples?" icon="text-align-start" href="https://www.ibm.com/docs/SSAVQO/deploy/web_chat_agent/tutorials/tutorials_lp.html" arrow="true" cta="Learn with walk-throughs" horizontal>
  Learn how to apply the features available for embedded chat into your implementation with guidance and examples.
</Card>
