# How to autoscroll a table in the dashboard

**URL:** <https://community.grafana.com/t/how-to-autoscroll-a-table-in-the-dashboard/81264>\
**Category:** Table Panel\
**Tags:** table-panel, dashboard\
**Created:** [February 8, 2023, 12:27pm UTC](https://community.grafana.com/t/how-to-autoscroll-a-table-in-the-dashboard/81264 "2023-02-08T12:27:54Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![jse](https://avatars.discourse-cdn.com/v4/letter/j/898d66/32.png) [@jse](https://community.grafana.com/u/jse)\
**Post date:** [February 8, 2023, 12:27pm UTC](https://community.grafana.com/t/how-to-autoscroll-a-table-in-the-dashboard/81264/1 "2023-02-08T12:27:54Z")

</div>

Hello,

I would like to set up an autoscroll on a dashboard table.  
This is because the dashboard will be on a monitor.  
Could you tell me if there is a feature that could help me?  
I haven’t found anything about it yet.

Thanks in advance

---

<div class="post-metadata">

**Author:** ![usman.ahmad](https://sea2.discourse-cdn.com/grafana/user_avatar/community.grafana.com/usman.ahmad/32/29706_2.png) [@usman.ahmad](https://community.grafana.com/u/usman.ahmad)\
**Post date:** [February 8, 2023, 12:48pm UTC](https://community.grafana.com/t/how-to-autoscroll-a-table-in-the-dashboard/81264/2 "2023-02-08T12:48:11Z")

</div>

Hi @jse ,

Well, we do not have such functionality which can do auto scroll of a Dashboard.

Also, to my understanding, you want to use the Tabel Panel and do auto-scroll.

One alternative way is to enable this feature by using (an extension) or JavaScript code within the browser.

2nd option would be to use Pagination in the table panel (which is not auto-scroll but can navigate the user correctly).

I hope this helps.

---

<div class="post-metadata">

**Author:** ![mikhailvolkov](https://sea2.discourse-cdn.com/grafana/user_avatar/community.grafana.com/mikhailvolkov/32/41625_2.png) [@mikhailvolkov](https://community.grafana.com/u/mikhailvolkov)\
**Post date:** [February 8, 2023, 1:42pm UTC](https://community.grafana.com/t/how-to-autoscroll-a-table-in-the-dashboard/81264/3 "2023-02-08T13:42:08Z")

</div>

@jse, It’s an interesting question. I would try scrolling through the Dynamic Text panel with the additional JavaScript code functionality we implemented recently.

> **[Dynamic Text plugin for Grafana | Grafana Labs](https://grafana.com/grafana/plugins/marcusolsson-dynamictext-panel/)**
>
> Data-driven text with Markdown and Handlebars support

---

<div class="post-metadata">

**Author:** ![cmartin510](https://avatars.discourse-cdn.com/v4/letter/c/bc8723/32.png) [@cmartin510](https://community.grafana.com/u/cmartin510)\
**Post date:** [April 18, 2023, 9:34pm UTC](https://community.grafana.com/t/how-to-autoscroll-a-table-in-the-dashboard/81264/4 "2023-04-18T21:34:02Z")

</div>

Would you happen to have an example of how to autoscroll the Dynamic Text plugin? I have the plugin working, and I can get it to autoscroll with javascript but I’m not sure what event handler to start triggering the scroll with Plus, I’m not confident in how to reference the objects in the panel correctly.

---

<div class="post-metadata">

**Author:** ![cmartin510](https://avatars.discourse-cdn.com/v4/letter/c/bc8723/32.png) [@cmartin510](https://community.grafana.com/u/cmartin510)\
**Post date:** [April 20, 2023, 10:17pm UTC](https://community.grafana.com/t/how-to-autoscroll-a-table-in-the-dashboard/81264/5 "2023-04-20T22:17:52Z")

</div>

After more work on the auto scroll, I came up with a solution using the Dynamic Text plugin and its JavaScript Code function. I thought I would share incase it helps someone else.

I created a table in the Dynamic Text plugin Content with an id (i.e. \<table id=“dataTable”…)

Then I use this JavaScript Code…

```auto
$(function() {
	dataTable = document.getElementById('dataTable');

	if (dataTable.parentElement.scrollHeight >= dataTable.parentElement.parentElement.offsetHeight) {
		if (dataTable.parentElement.parentElement.getAttribute('listener') !== 'true') {
			dataTable.parentElement.parentElement.setAttribute('listener', 'true');
			scrollWindow();
		};
	};
});

function scrollWindow() {
	parentWindow = document.getElementById('dataTable').parentElement.parentElement;

	bottomOfWindow = parentWindow.scrollHeight - parentWindow.offsetHeight;

	if (parentWindow.scrollTop < bottomOfWindow) {
		parentWindow.scrollBy(0,1);
		setTimeout(scrollWindow, 50);
	} else {
		setTimeout(function() {
			parentWindow.scrollTo({top: 0, behavior: 'smooth'})
		}, 5000);

		setTimeout(scrollWindow, 10000);
	};
};

```

This causes the panel to scroll if needed. When it gets to the bottom it waits 5 sec, scrolls back to the top, waits another 5 sec, and starts scrolling again.

---

<div class="post-metadata">

**Author:** ![mikhailvolkov](https://sea2.discourse-cdn.com/grafana/user_avatar/community.grafana.com/mikhailvolkov/32/41625_2.png) [@mikhailvolkov](https://community.grafana.com/u/mikhailvolkov)\
**Post date:** [April 21, 2023, 12:04am UTC](https://community.grafana.com/t/how-to-autoscroll-a-table-in-the-dashboard/81264/6 "2023-04-21T00:04:43Z")

</div>

@cmartin510 Awesome, and thank you for sharing the solution!

I will test and add it to the documentation.

---

<div class="post-metadata">

**Author:** ![mikhailvolkov](https://sea2.discourse-cdn.com/grafana/user_avatar/community.grafana.com/mikhailvolkov/32/41625_2.png) [@mikhailvolkov](https://community.grafana.com/u/mikhailvolkov)\
**Post date:** [April 21, 2023, 2:35pm UTC](https://community.grafana.com/t/how-to-autoscroll-a-table-in-the-dashboard/81264/7 "2023-04-21T14:35:55Z")

</div>

@cmartin510 Works like a charm.

![scrolling](https://us1.discourse-cdn.com/grafana/original/3X/f/1/f116407eb3a6c36287a23f1e1ca9e28a6b510375.gif)

Updated in the documentation.

> **[JavaScript Code | Volkov Labs](https://volkovlabs.io/plugins/volkovlabs-dynamictext-panel/code/#auto-scroll)**
>
> JavaScript Code allows adding Handlebars helpers and Event handlers.

I refactored code a little

```auto
const scrollWindow = () => {
  parentWindow =
    document.getElementById("dataTable").parentElement.parentElement;
  bottomOfWindow = parentWindow.scrollHeight - parentWindow.offsetHeight;

  /**
   * Scroll
   */
  if (parentWindow.scrollTop < bottomOfWindow) {
    parentWindow.scrollBy(0, 1);
    setTimeout(scrollWindow, 50);
    return;
  }

  /**
   * Scroll to the Top
   */
  setTimeout(function () {
    parentWindow.scrollTo({ top: 0, behavior: "smooth" });
  }, 1000);

  /**
   * Start scrolling again
   */
  setTimeout(scrollWindow, 1000);
};

$(() => {
  dataTable = document.getElementById("dataTable");

  /**
   * Avoid scrolling for short tables
   */
  if (
    dataTable.parentElement.scrollHeight <
    dataTable.parentElement.parentElement.offsetHeight
  ) {
    return;
  }

  /**
   * Already set to scroll
   */
  if (dataTable.parentElement.parentElement.getAttribute("listener")) {
    return;
  }

  dataTable.parentElement.parentElement.setAttribute("listener", true);
  scrollWindow();
});

```

---

<div class="post-metadata">

**Author:** ![usman.ahmad](https://sea2.discourse-cdn.com/grafana/user_avatar/community.grafana.com/usman.ahmad/32/29706_2.png) [@usman.ahmad](https://community.grafana.com/u/usman.ahmad)\
**Post date:** [April 27, 2023, 11:19am UTC](https://community.grafana.com/t/how-to-autoscroll-a-table-in-the-dashboard/81264/8 "2023-04-27T11:19:14Z")

</div>

Just wanted to say this is really cool stuff !! 🕶

---

<div class="post-metadata">

**Author:** ![pcsouzafv1](https://avatars.discourse-cdn.com/v4/letter/p/57b2e6/32.png) [@pcsouzafv1](https://community.grafana.com/u/pcsouzafv1)\
**Post date:** [November 6, 2024, 1:51pm UTC](https://community.grafana.com/t/how-to-autoscroll-a-table-in-the-dashboard/81264/9 "2024-11-06T13:51:35Z")

</div>

Dear, good morning!  
Does the table increase automatically as data increases in the rows, without needing this scroll ?

---

<div class="post-metadata">

**Author:** ![zyn10](https://avatars.discourse-cdn.com/v4/letter/z/e0b2c6/32.png) [@zyn10](https://community.grafana.com/u/zyn10)\
**Post date:** [May 20, 2025, 10:06am UTC](https://community.grafana.com/t/how-to-autoscroll-a-table-in-the-dashboard/81264/10 "2025-05-20T10:06:28Z")

</div>

I have created an extension for Chrome. After downloading please change the URLs of your pages and you are good to go.

> **[GitHub - zyn10/GrafanaScrollExtention](https://github.com/zyn10/GrafanaScrollExtention)**
>
> Contribute to zyn10/GrafanaScrollExtention development by creating an account on GitHub.

---

<div class="post-metadata">

**Author:** ![darrenwoodford](https://avatars.discourse-cdn.com/v4/letter/d/fbc32d/32.png) [@darrenwoodford](https://community.grafana.com/u/darrenwoodford)\
**Post date:** [May 19, 2026, 10:36am UTC](https://community.grafana.com/t/how-to-autoscroll-a-table-in-the-dashboard/81264/11 "2026-05-19T10:36:35Z")

</div>

Great work! Shame this isn’t a native feature for Tables. I think it would be good if the Design and Development team could give more consideration to usage on large TV/wallboards without any keyboard or mouse attached. The Playlist feature is a good start though.
