Inferensys

Glossary

URDF (Unified Robot Description Format)

URDF is an XML-based file format used to describe the kinematic and dynamic properties of a robot for simulation and visualization.
Stylish WeWork-like workspace with hot desks and document wall, professional searching through enterprise knowledge base on a mounted ultrawide display, warm industrial pendants overhead.
ROBOT MODELING STANDARD

What is URDF (Unified Robot Description Format)?

URDF is the foundational XML format for describing a robot's physical structure and properties for simulation and visualization.

The Unified Robot Description Format (URDF) is an XML-based specification used to define a robot's kinematic tree, dynamic properties, and visual representation. It describes a robot as a collection of links (rigid bodies) connected by joints (revolute, prismatic, fixed), specifying their inertial parameters, collision geometries, and visual meshes. This standardized description is parsed by middleware like ROS (Robot Operating System) and physics simulators such as Gazebo and PyBullet to spawn and simulate the robot in a virtual environment.

While essential, URDF has limitations: it describes a robot with a single, tree-like structure and lacks support for closed kinematic chains, constraint-based solvers, or complex actuator models. For more advanced simulation needs, the Simulation Description Format (SDF) is often used as a more feature-rich successor. URDF remains the primary format for defining robot models within the ROS ecosystem, serving as the critical bridge between a robot's mechanical design and its software-driven simulation and control stack.

XML SCHEMA

Core Components of a URDF File

A URDF file is an XML tree that defines a robot's physical structure and properties. Each component is a distinct XML element with specific attributes and child elements.

01

Link Element

The <link> element defines a rigid body segment of the robot, representing a physical part like a chassis, arm link, or wheel. Each link has a unique name attribute. Its properties are defined by child elements:

  • <inertial>: Specifies the link's mass and 3D inertia tensor, crucial for dynamic simulation.
  • <visual>: Describes the link's appearance for visualization, using <geometry> (box, cylinder, mesh) and <material>.
  • <collision>: Defines a simplified geometry used for physics collision detection, which is often a less complex mesh than the visual geometry to improve simulation performance.
02

Joint Element

The <joint> element defines the kinematic relationship between two links. It has a name, a type (e.g., revolute, prismatic, fixed), and specifies a parent and child link. Key child elements include:

  • <origin>: The pose (xyz, rpy) of the child link frame relative to the parent link frame.
  • <axis>: The unit vector (xyz) around or along which the joint moves. Default is (1, 0, 0).
  • <limit>: For non-fixed joints, specifies the lower and upper position bounds, velocity limit, and effort (force/torque) limit.
  • <dynamics>: Defines physical damping and static friction values for the joint.
03

Robot Element & Tree Structure

The <robot> element is the root XML tag of a URDF file, with a name attribute. It contains all <link> and <joint> elements. The joint definitions create a tree structure, where:

  • One link is designated the base_link, typically with no parent joint.
  • All other links are connected to this tree via their parent joints.
  • This structure prohibits closed kinematic chains (loops), which is a key limitation of the basic URDF format. The tree defines the robot's kinematic chain from base to end-effector.
04

Geometry and Visual Representation

The <geometry> tag, used within <visual> and <collision> elements, defines the shape of a link. Primitive types are:

  • <box>: Defined by size (length in x, y, z).
  • <cylinder>: Defined by radius and length.
  • <sphere>: Defined by radius.
  • <mesh>: References an external 3D file (e.g., .stl, .dae) via the filename attribute, allowing for complex, custom shapes. The <material> tag with a <color> or <texture> defines the visual appearance in simulators like RViz.
05

Inertial Properties

The <inertial> element is mandatory for accurate dynamic simulation. It contains:

  • <origin>: The pose of the center of mass relative to the link's coordinate frame.
  • <mass>: The scalar mass value in kilograms.
  • <inertia>: The 3x3 rotational inertia matrix, specified by the six unique values (ixx, ixy, ixz, iyy, iyz, izz).

These values are essential for physics engines to correctly compute how the robot responds to forces and torques. Approximating these values from CAD models or through system identification is a critical step in simulation setup.

06

Related Formats: SDF and Xacro

URDF has limitations, leading to the use of related formats:

  • SDF (Simulation Description Format): A more comprehensive XML format that can describe entire simulated worlds, not just a single robot. It supports nested models, closed kinematic chains, and more detailed sensor and physics properties. It is the native format for Gazebo.
  • Xacro (XML Macros): A macro language used with URDF to address its verbosity and lack of reusability. Xacro allows for:
    • Property Variables: Define constants (e.g., $(arm_length)).
    • Macros: Create reusable code blocks for common components.
    • Conditional Statements and Math: Programmatically generate URDF structures. A Xacro file is processed to generate a plain, expanded URDF file for use by simulators.
ROBOTIC SIMULATION PIPELINE

How URDF Works in a Simulation Pipeline

The Unified Robot Description Format (URDF) is the foundational data structure that defines a robot's physical properties for simulation, enabling the physics engine to compute its motion and interactions.

A URDF file is an XML document that describes a robot as a kinematic tree of links (rigid bodies) connected by joints (revolute, prismatic, fixed). It specifies each link's visual geometry, collision geometry, inertial properties (mass, center of mass, inertia tensor), and joint limits. This model provides the physics engine with the necessary parameters to perform rigid-body dynamics calculations, such as forward and inverse dynamics, and to resolve contact forces during collisions.

In the simulation pipeline, the URDF is loaded by a simulator like Gazebo, PyBullet, or MuJoCo. The physics engine uses the URDF's inertial tensors and joint constraints to construct the system's equations of motion. During each time step, the engine solves these equations, applying control inputs from a Model Predictive Control or Reinforcement Learning policy to compute new joint positions, which are then rendered. This closed loop allows for testing and training in a virtual environment before Sim-to-Real Transfer to physical hardware.

ROBOT DESCRIPTION FORMATS

URDF vs. SDF: A Format Comparison

A technical comparison of the two primary XML-based formats used to define robots and environments for physics-based simulation.

Feature / CapabilityURDF (Unified Robot Description Format)SDF (Simulation Description Format)

Primary Purpose

Describe a single robot's kinematic tree

Describe an entire simulated world (robots, static objects, lighting, sensors)

Model Nesting

Closed Kinematic Loops

Default Physics Properties

Basic inertial and collision geometry

Comprehensive material, surface, and contact properties

Sensor Definition

Limited (via plugins)

Native and extensive (cameras, IMU, lidar, contact)

Joint Types

Revolute, Prismatic, Continuous, Fixed, Floating, Planar

All URDF types plus Screw, Universal, Ball, Gearbox, Revolute2

File Extension

.urdf, .xacro

.sdf

World Description

Not supported (robot only)

Native support for multiple models, environments, and global physics

Plugin Architecture

Supported (ROS-centric)

Supported (engine-agnostic)

Standardization Body

ROS community

Open Source Robotics Foundation (OSRF)

ROBOTIC MODELING

Primary Use Cases for URDF

The Unified Robot Description Format (URDF) is the foundational XML schema for defining a robot's physical structure in simulation and visualization. Its primary applications span from basic kinematic modeling to complex simulation pipelines.

01

Kinematic & Dynamic Modeling

URDF provides the canonical data structure for defining a robot's kinematic tree, specifying the hierarchical relationship between links (rigid bodies) and joints (revolute, prismatic, fixed). It encodes essential dynamic properties, including:

  • Inertial tensors (mass, center of mass, inertia matrix) for each link.
  • Joint limits for position, velocity, and effort.
  • Transmission elements to map actuator outputs to joint movements. This model is parsed by middleware like ROS to compute forward/inverse kinematics and dynamics for control and planning.
02

Physics-Based Simulation

URDF files are the standard input for major physics engines like Gazebo, PyBullet, and MuJoCo. The format describes the collision geometries (often simplified meshes) and inertial properties required for accurate rigid-body dynamics and contact resolution. Simulation plugins within the URDF can attach virtual sensors (e.g., IMU, LiDAR, camera) and define actuator models (PID gains, torque limits) to create a high-fidelity, interactive digital twin of the robot for training and testing.

03

3D Visualization & Debugging

Tools like RViz (ROS) and Foxglove parse URDF files to generate real-time 3D visualizations of the robot model. This is critical for:

  • Debugging kinematic chains and sensor placements.
  • Visualizing planned trajectories, point clouds, and coordinate frames (TF).
  • Providing an operator interface for teleoperation and monitoring. The <visual> tags in URDF define the meshes, materials, and colors used for this representation, which is distinct from the simpler collision geometries.
04

Motion Planning & Control

Motion planning libraries such as MoveIt ingest the URDF model to perform collision-aware path planning. The planner uses the robot's kinematic constraints and collision geometries to compute trajectories that avoid self-collision and environmental obstacles. Similarly, control stacks use the URDF's dynamic parameters for model-based controllers like computed-torque control or to formulate the dynamics for Model Predictive Control (MPC).

05

System Integration & Documentation

A URDF file serves as a single source of truth for a robot's mechanical design, bridging hardware engineering and software development. It acts as:

  • A contract between mechanical CAD design and software control.
  • Documentation for the robot's topology, coordinate frames, and capabilities.
  • The input for automated code generation for kinematics and for configuring middleware drivers. This standardized description is essential for integrating perception, planning, and control modules into a cohesive system.
06

Sim-to-Real Pipeline

URDF is the starting point for Sim-to-Real transfer workflows. A high-fidelity URDF model, often extended with precise actuator and sensor noise models, is used in simulation to train Reinforcement Learning policies or to test classical controllers. Techniques like Domain Randomization modify URDF parameters (e.g., masses, inertias) during training to create robust policies. The same URDF, with calibrated parameters, is then used on the physical robot, ensuring consistency between the simulated training environment and the real hardware deployment.

URDF

Frequently Asked Questions

The Unified Robot Description Format (URDF) is the foundational XML schema for defining a robot's physical structure in simulation and visualization. These questions address its core purpose, structure, limitations, and role in the modern robotics software stack.

URDF (Unified Robot Description Format) is an XML-based file format used to describe the kinematic structure, visual geometry, and inertial properties of a robot for simulation and visualization. Its primary purpose is to provide a standardized, human-readable way to define a robot's links (rigid bodies) and joints (the connections between them) so that software like the Robot Operating System (ROS), Gazebo, and PyBullet can parse the model to simulate its physics, render it in 3D, and perform kinematic calculations. It serves as the digital blueprint from which simulation engines build a virtual, interactive counterpart of the physical machine.

Prasad Kumkar

About the author

Prasad Kumkar

CEO & MD, Inference Systems

Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.

His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.