Webots: the classroom favorite
Cross-platform, GUI-first, and perfect for teaching cohorts with mixed hardware. The simulator that doesn't try to be cutting-edge but consistently delivers.
Webots is the unsung simulator. Not the fastest, not the most photorealistic, not the most popular in research. But it runs on Windows, macOS, and Linux out of the box; it boots in seconds; it has a polished GUI; and it ships with a library of pre-built robots ready to drive. For teaching robotics to a cohort with mixed hardware, Webots is hard to beat.
Why Webots fits classrooms
- Cross-platform: same binary works on Windows, macOS, and Linux. No "this only runs on Ubuntu 22" gotchas.
- One-click install: download, run, simulator opens. No CUDA, no Docker, no ROS workspace setup.
- GUI-first: drag-and-drop world editing, real-time parameter tweaking, click-to-inspect joint state. Good for visual learners.
- Pre-built robots: ~50 robots ship with the install. Pioneer 3, NAO, Atlas, e-puck, Khepera, TurtleBot — drag onto a world and they work.
- Multi-language API: C, C++, Python, Java, MATLAB. Pick what your students know.
- Open-source since 2018: Apache 2.0; previously commercial; the open-source release is fully featured.
The 20-line minimum example
Create a controller in Python:
from controller import Robot
robot = Robot()
timestep = int(robot.getBasicTimeStep())
# Get devices
left_motor = robot.getDevice('left motor')
right_motor = robot.getDevice('right motor')
left_motor.setPosition(float('inf'))
right_motor.setPosition(float('inf'))
# Drive forward
left_motor.setVelocity(1.0)
right_motor.setVelocity(1.0)
while robot.step(timestep) != -1:
pass
That's a complete controller. Drop it onto an e-puck robot in a Webots world; it drives. Twenty lines. No build system; no launch file.
The world file (.wbt)
Webots worlds are .wbt files — a simple text format describing the scene tree:
#VRML_SIM R2024a utf8
WorldInfo {
basicTimeStep 32
}
Viewpoint {
orientation -0.5 0.5 0.7 1.5
position 0 -1.5 0.5
}
Background { skyColor [ 0.4 0.6 1.0 ] }
DEF FLOOR Floor {
size 5 5
}
DEF EPUCK E-puck {
translation 0 0 0
controller "my_controller"
}
Concise. The Webots GUI lets you edit this visually; the underlying file is human-readable. Version control friendly.
Sensors and actuators
Standard library:
- Distance sensors (IR, ultrasonic, lidar).
- Camera, RangeFinder (depth).
- GPS, Compass, IMU.
- Force sensors.
- Servo motors, linear motors, brushless motors.
All exposed via the controller API. Read sensor values; command actuator targets; the simulator handles the physics.
Strengths over alternatives
- Friendlier than Gazebo for first-time users (faster setup).
- More polished GUI than PyBullet.
- Cross-platform without WSL/Docker (where Gazebo struggles on Windows/macOS).
- Better pre-built robot library than MuJoCo for legacy robots.
Weaknesses
- Slower physics than MuJoCo for contact-rich sim. Quadrupeds work but feel sluggish.
- Smaller research community: most papers use MuJoCo, Isaac, Gazebo, or Drake — not Webots.
- Limited GPU parallelism: not designed for batched RL training.
- Less ROS integration than Gazebo. ROS bridge exists but is less mature.
When Webots wins
- Teaching: undergrad robotics course on a mix of student laptops.
- RoboCup junior leagues: standardized worlds + multi-language support.
- Quick demos: load a robot, write a 20-line controller, show students how a wall-follow works.
- Cross-platform CI: tests that have to run on macOS Github Actions runners.
When to switch to something else
- You need ROS 2 deeply integrated → Gazebo.
- You're training RL at scale → MuJoCo MJX or Isaac Lab.
- You need photorealistic rendering → Isaac.
- You're doing optimization-heavy research → Drake.
Webots' niche is "first simulator a student touches." Once they outgrow it, they migrate.
The 2026 production reality
Webots use cases in 2026:
- University courses on robotics (introductory).
- RoboCup educational leagues.
- Quick prototyping for hobbyists who don't want to install heavy stacks.
- CI tests on macOS where Gazebo doesn't work cleanly.
Cyberbotics maintains it actively; the open-source community contributes regularly. Stable, predictable, useful for what it's for.
Common gotchas
- Controller path: Webots looks for a controller folder under your project; case-sensitive on Linux. Bug source.
- Time-step: too small = slow sim; too large = unstable contact. Start with 32 ms; tune.
- Real-time vs fast mode: F8 toggles. Easy to forget; debugging at fast mode is confusing.
- External controller mode: connect a Python script outside Webots via TCP. Powerful but trickier than embedded controllers.
Exercise
Install Webots. Load the e-puck demo world. Modify the supplied controller to make the e-puck follow a wall. Total time: under an hour. The friction of getting started is uniquely low; that's the value Webots delivers.
Next
URDF, MJCF, USD — the three formats that describe robots to all these simulators. How to convert between them without losing fidelity.
Comments
Sign in to post a comment.