ioBroker vis-2 adapter – smart home interface

Would you like to see which lights are on and the current living room temperature in one place, and switch the lights with a single click? With the ioBroker vis-2 adapter, you can create a custom smart home dashboard that works in a browser on any device.

Created: November 2026

Prerequisite: A working ioBroker server

In this guide, we will install the ioBroker vis-2 adapter and build a working dashboard that you can open in a browser. We will display a room’s temperature, add a light switch, and explore how to use custom JavaScript and CSS in vis-2.

What can you do with vis-2?

Vis-2 is ioBroker’s graphical visualization interface. It lets you display smart home data and control devices through a dashboard that opens in a browser. You do not need programming skills to get started: you can assemble the interface in the editor by dragging elements into place and adjusting their settings. More advanced users can customize vis-2 with scripts and CSS.

The vis-2 dashboard in runtime mode
An example of a vis-2 dashboard opened in a browser.

How is vis-2 organized?

Vis-2 is organized into three levels:

  • Project: the complete dashboard. You can create several projects in ioBroker vis-2, for example one for your home devices and another for testing.
  • View: you can create as many views as you need within a project, such as one for the living room and another for the bedroom. You can also bring them together on an overview page.
  • Widget: the building block of a view. Widgets display or control your devices’ data points.

What can widgets do?

Some widgets display a value, such as the living room temperature or humidity.

Other widgets control devices. For example, if a data point is writable and you have the required permissions, you can switch a light on or off with a single click.

Some widgets combine both functions: they display a data point’s value and let you change it. Thermostats, blind controls, and dimmers are examples.

You will also find widgets for charts, images, HTML content, and other controls. There are plenty of options for building your own interface.

One dashboard, different uses

You can adapt the layout of each view to the way you plan to use it. A wall-mounted tablet might show a broad overview of your home, while a phone may benefit from a simpler view with fewer elements.

You can build a vis-2 interface with flexible elements that adjust to one another, as well as elements placed at specific positions exactly where you want them.

Installing vis-2

Install vis-2 in the usual way. Open the “Adapters” page in the ioBroker Admin interface and search for the vis-2 adapter. Click the blue three-dot button on its card to turn the card over, then click “+” to install an instance.

The vis-2 adapter card on the ioBroker Adapters page
Install the vis-2 adapter from the ioBroker Adapters page.

The vis-2 license

Vis-2 requires a license. For private use, you can request a free ioBroker community license with an account created at iobroker.net. The system checks the community license online when the adapter starts, so an internet connection is needed at that point.

You can find the current license options and terms on the VIS-2 pricing page. Enter your license in the VIS-2 instance settings, then save the settings.

The VIS-2 instance settings page with the license field
Enter the license in the VIS-2 instance settings.

After installation and configuration, the vis-2 instance restarts. Check the “Instances” page to confirm that it has started. A running vis-2 instance shows a green status indicator.

The running vis-2 instance has a green status indicator on the ioBroker Instances page
The green status indicator shows that the vis-2 instance is running.

Creating your first vis-2 project

On the “Instances” page, open the vis-2 editor using the link associated with the instance. Click the fourth icon next to vis-2.0.

The vis-2.0 instance and its launch icons on the Instances page
You can find the vis-2.0 launch icon on the Instances page.

A pop-up window contains two buttons. The yellow “vis-2 Editor” button opens the editor. The green “vis-2 Runtime” button opens the default view in runtime mode.

Click “vis-2 Editor” now to start building the dashboard.

The vis-2 Editor and vis-2 Runtime buttons in the pop-up window
The yellow button opens the editor; the green button opens the dashboard.

When you use vis-2 for the first time, create a new project and give it an easy-to-recognize name, such as “Home“.

Creating a new project when vis-2 starts for the first time
Give your new vis-2 project a name during the first launch.

Once the project has been created, the empty editor opens.

The empty vis-2 editor for a new project
This is where you will assemble the views in your new project.

The “Views” menu opens a list of the views you have created. Click a view’s name to open it in the editor.

The list of views opened from the vis-2 Views menu
Use the Views window to choose a view from the project.

A view called “default” is created within the project. You can use it or create a new view.

Adding a new view to the vis-2 project
You can add a new view alongside the default view.

Displaying the room temperature

We can build the views in our project using different widgets. The “Palette” panel on the left side of the editor contains the available widgets.

For this example, choose a “Thermostat” widget and drag it from the Palette onto the central editing area. You can adjust the position and size of freely positioned elements by dragging them. Elements in a relative layout follow the order of their section and cannot be moved to an arbitrary position in the same way.

The widget’s settings now appear in the “Attributes” panel on the right.

Adding a Thermostat widget in the vis-2 editor
Drag the Thermostat widget from the Palette onto the view.

An empty widget is not very useful until we give it a value to display. Assign a data point to the “Common/Measured temperature” attribute by clicking the “…” button next to its input field. A data point selection window opens, where you can choose the room temperature data point.

Selecting a temperature data point for the Thermostat widget
Assign the room temperature data point to the Measured temperature field.

After you select the data point, the Thermostat widget displays the current temperature. The “Attributes” panel offers many options for changing the widget’s appearance and behavior, so feel free to experiment with them.

The configured Thermostat widget in the vis-2 editor
The configured widget already displays the temperature in the editor.

Let’s see the result: opening the vis-2 runtime

Open the view you have created by selecting “Open runtime in new window” from the drop-down menu in the upper-right corner.

The Open runtime in new window menu item in the vis-2 editor
You can open the view you are building in a separate runtime window.

The view opens in a new browser tab, with the Thermostat widget showing the current temperature.

The vis-2 view displaying the temperature in runtime mode
The first widget also shows the current temperature in runtime mode.

The next example: switching the room light

In the previous example, we displayed the room temperature. Now let’s make the dashboard interactive by adding a switch for the room light.

Drag a “Switch” widget from the “Palette” panel into the editor. Set its size and position by dragging it or by using the “CSS Common” section of the “Attributes” panel.

To control the room light with this switch, we need to assign its data point. Add the room light’s data point to the “Object ID” property as shown in the previous example. In my setup, it is “mqtt.0.roomLamp”.

A Switch widget with the roomLamp data point assigned in the vis-2 editor
Assign the light’s data point to the Switch widget’s Object ID field.

Testing the switch in vis-2 runtime mode

As before, select “Open runtime in new window” from the drop-down menu in the upper-right corner to open the view.

The new switch appears below the temperature display. Click it to try it out.

The temperature display and light switch on a vis-2 view
The new switch appears below the temperature display in runtime mode.

The Switch widget changes state and, if everything is connected correctly, the room light turns on.

The light switch in its on state on the vis-2 view
The switch in its on state on the vis-2 dashboard.

We can check the change on the ioBroker “Objects” page: the room light data point assigned to the Switch widget now has the value “true”.

The roomLamp data point showing the value true on the ioBroker Objects page
The new value of the light’s data point is also visible on the ioBroker Objects page.

More possibilities: vis-2 widget packages

The vis-2 “Palette” panel already contains many widgets. You can expand the selection by installing additional widget packages. On the ioBroker “Adapters” page, enter vis-2 in the search field and choose a package that suits your project.

Additional widget packages for vis-2 on the ioBroker Adapters page
Search the Adapters page for additional vis-2 widget packages.

Custom solutions: vis-2 scripts and CSS

Formatting a data point with a script

What if we want to display the room temperature with one decimal place, but the data point contains several decimal places?

The roomTemperature data point showing a value with several decimal places
The raw value of the temperature data point contains several decimal places.

In VIS-2, we can generate a widget’s text using a data binding that contains a JavaScript expression.

Add a “Text” widget in the vis-2 editor. On the “Attributes” tab, enter the following expression in its “Text” field:

 {t:mqtt.0.roomTemperature; 'Room temperature: '+Number(t).toFixed(1) + ' °C'}

The expression reads the value of the “roomTemperature” data point. JavaScript’s “toFixed()” method rounds it to one decimal place and returns the result as a string.

The temperature-formatting data binding in the Text widget settings
The expression in the Text widget formats the temperature to one decimal place.

We can see the result in vis-2 runtime mode: the “Text” widget displays the room temperature with one decimal place.

Temperature displayed with one decimal place in a vis-2 Text widget
The formatted temperature on the finished dashboard.

Building a live clock card

First, drag an “HTML” widget onto the editing area.

Adding an HTML widget to a vis-2 view
An HTML widget provides the structure for the clock card.

On the widget’s “Attributes” tab, click the pencil icon beside the “HTML” field. Paste the following HTML into the window that opens:

<div class="mht-vis2-clock">
  <div class="mht-vis2-clock-label">Local time</div>
  <div class="mht-vis2-clock-time">--:--:--</div>
  <div class="mht-vis2-clock-date">Loading…</div>
</div>
The clock card's HTML in the vis-2 HTML widget
The HTML provides separate places for the clock label, time, and date.

Next, paste the JavaScript that updates the clock into the “Scripts” tab of the view’s “Attributes” panel.

(() => {
  // Prevent multiple timers if the script runs again.
  if (window.mhtVis2ClockTimer) {
    clearInterval(window.mhtVis2ClockTimer);
  }

  function updateClock() {
    const now = new Date();

    document.querySelectorAll(".mht-vis2-clock").forEach((card) => {
      const time = card.querySelector(".mht-vis2-clock-time");
      const date = card.querySelector(".mht-vis2-clock-date");

      if (time) {
        time.textContent = now.toLocaleTimeString("en-GB");
      }

      if (date) {
        date.textContent = now.toLocaleDateString("en-GB", {
          year: "numeric",
          month: "long",
          day: "numeric"
        });
      }
    });
  }

  updateClock();
  window.mhtVis2ClockTimer = setInterval(updateClock, 1000);
})();
JavaScript for updating the clock on the Scripts tab
The script on the Scripts tab updates the clock every second.

Then open the “CSS” tab in the view’s “Attributes” panel and style the clock card. The CSS does not contain language-specific text, so we can use the same rules as in the Hungarian version.

.mht-vis2-clock {
  box-sizing: border-box;
  padding: 1.25rem 1.5rem;
  color: #1e293b;
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  border-left: 6px solid #2563eb;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.18);
  text-align: center;
}

.mht-vis2-clock-label {
  color: #0f3d70;
  font-size: 0.9rem;
  font-weight: 700;
}

.mht-vis2-clock-time {
  margin: 0.35rem 0;
  font-size: clamp(1.8rem, 5vw, 3rem);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.mht-vis2-clock-date {
  color: #475569;
  font-size: 0.95rem;
}
CSS rules for the clock card on the CSS tab
The CSS sets the clock card’s colors, border, and font sizes.

The date and time come from the clock of the device opening the page. This example does not read an ioBroker data point.

Open the completed VIS-2 view in runtime mode and check that the clock updates every second.

The completed clock card in vis-2 runtime mode
The clock card combines HTML, JavaScript, and CSS.

VIS-2 troubleshooting: when something does not work

  • The VIS-2 instance does not start. Check the instance status and the ioBroker log. Also check whether you have entered the license and whether an internet connection is available when the community license is verified.
  • The editor or completed view does not open. Check the status of the VIS-2 and web server instances. Open the link from the Instances page.
  • A widget does not show a value. Check the selected data point’s ID and current value on the ioBroker Objects page, then check the data point assigned to the widget.
  • The switch is visible but does not control the device. Check whether the selected data point is writable and whether the widget is connected to the data point that controls the device.

← More ioBroker tutorials