How to start a website using rosbridge?


I would like to develop a webpage for control of the robot.
I’ve installed rosbridge
I’ve created one html file. Here is the code:

<!DOCTYPE html>
<meta charset="utf-8" />

<script type="text/javascript" src=">

<script type="text/javascript" type="text/javascript">
  var ros = new ROSLIB.Ros({
    url : 'ws://'


  ros.on('connection', function() {
    document.getElementById("status").innerHTML = "Connected";

  ros.on('error', function(error) {
    document.getElementById("status").innerHTML = "Error";

  ros.on('close', function() {
    document.getElementById("status").innerHTML = "Closed";

  <h1>Simple ROS User Interface</h1>
  <p>Connection status: <span id="status"></span></p>
  <p>Last /txt_msg received: <span id="msg" ></span></p>

The name of the html file is gui.html
I’ve started the rosbridge:
roslaunch rosbridge_server rosbridge_websocket.launch

Then I wanted to check if I can load my webpage
I found the IP address of my raspberry PI where was created my webpage using:

hostname -I

I wanted to load my webpage from my laptop using this line:

Unfortunately I can’t load the webpage! Could you please help me to resolve this issue? Thank you in advance!

The image has been changing for a very long time now. Some of the changes introduced webpages at specific port numbers. I implemented a webpage with javascript 6 years ago so this may not be helpful any longer. I offer this just in case something in it makes sense to you.

I will put in the code I used but I have lost track of how to get this page to show up. It did use rosbridge. Again, I offer this not as a solution but as what I did 6 years ago so ‘maybe’ something is of value. My webpage on this robot is here: FiddlerBot A Thinking Bot-
You can see the page that these code modules implement or perhaps close to it on above link.

Well I have just found that I cannot post it here due to this forum only allows pictures.

Send an email to and in subject say Attention Mark for Webpage

This will allow me to get you these files.

I feel what you really want is how to get your webpage setup since you have your own html and javascript already. This part of it I have long forgotten and don’t have notes.

It is fun having webpage ability so I wish you best of luck in your project

On our GitHub page we have some old kinetic code for robot commander that might still work. The robot commander android app is still available and should work with a Noetic version of Magni bring up base launch,