An independent field manual for physical AIRev. 2026.12 · 7 chapters · 40 articles
Physical AI Handbook

Domain randomization: how sim-trained robots survive reality

Domain randomization varies a simulator's visuals and physics during training so robot policies transfer to hardware. How it works, what to randomize, limits.

Key takeaways06 / Simulation & Data
  • Domain randomization is a training technique that randomly varies a simulator's visual and physical parameters so that a robot policy trained only in simulation still works on real hardware.
  • Visual randomization varies textures, lighting, camera pose and distractor objects to close the sensing gap, while dynamics randomization varies mass, friction, motor strength, latency, sensor noise and terrain to close the physics and timing gap.
  • Wider randomization ranges are not always better: published quadruped studies found that dynamics randomization trades peak performance for robustness and can produce overly conservative policies.
  • Automatic domain randomization, introduced by OpenAI in 2019, starts from a single simulated environment and widens each parameter range only as the policy masters the current one.
  • Domain randomization works best for legged locomotion and remains weakest for contact-rich manipulation, deformable objects and camera perception of real clutter, where the simulator is wrong in ways no parameter range covers.

Domain randomization is a training technique in which a simulator’s parameters are varied randomly from one training episode to the next, so that a robot policy trained only in simulation still works on real hardware. The parameters include what the robot sees (textures, lighting, camera placement) and what it feels (mass, friction, motor strength, delays). Because the policy cannot rely on any single version of the simulated world, it learns behavior that holds across a range, and the bet is that reality falls inside that range.

It is the workhorse answer to the sim-to-real gap, the performance lost when a simulation-trained policy runs on a physical robot. This article covers where the idea came from, its two families, the results that made it standard practice, how to set the ranges, and where it stops working.

Where did domain randomization come from?

The standard reference is a March 2017 paper by Josh Tobin and colleagues at OpenAI and UC Berkeley. They trained an object detector only on simulated images, rendered with deliberately unrealistic random textures, and then ran it on real camera images. Across training images they varied the number and shape of distractor objects, object positions and textures, the camera’s position, orientation and field of view, the lighting, and the image noise.

The detector located objects to within about 0.6 in (1.5 cm), accurately enough to guide a robot grasping in clutter. The paper’s hypothesis was that, with enough variability in the simulator, the real world “may appear to the model as just another variation.”

The idea was not entirely new, and the paper says so. It names Sadeghi and Levine’s CAD2RL (2016) as the closest prior work: a quadrotor collision-avoidance policy trained only on rendered images with heavily randomized rendering, then flown indoors.

The physics half followed within months. In October 2017, Xue Bin Peng and co-authors, also at OpenAI and UC Berkeley, randomized 95 parameters of a simulated puck-pushing task: link masses, joint damping, the puck’s mass and friction, table height, controller gains, the time between actions, and observation noise. A recurrent policy trained this way succeeded in 89% of trials on a real Fetch arm. A policy trained without randomization failed every real trial.

Visual vs. dynamics randomization

The two families attack different parts of the gap and can be used separately or together.

Family What gets randomized Which gap it targets Typical use
Visual randomization Textures, colors and materials; number and position of lights; camera pose and field of view; distractor objects; image noise Sensing: rendered images do not look like real camera images Camera-based policies and perception models, mostly in manipulation
Dynamics randomization Link and payload mass, center of mass, friction, motor strength and controller gains, latency and control timing, sensor noise and bias, terrain shape, random pushes Physics, actuators and timing: the simulated robot does not move like the real one Locomotion, and any policy that makes contact

A walking policy that uses only joint encoders and an inertial sensor needs dynamics randomization alone. A camera-driven manipulation policy usually needs both.

Dynamics randomization pairs naturally with memory. Peng’s recurrent policy beat memoryless versions on the real arm because a policy that remembers its recent states and actions can infer which dynamics it is facing and adjust.

Landmark results

Dexterous manipulation: Dactyl and the Rubik’s Cube

In 2018, OpenAI trained a Shadow Dexterous Hand to reorient a block using policies learned entirely in simulation. The team randomized physics (friction, object dimensions, masses, joint damping, actuator gains, even gravity) and visuals (camera pose, lighting, materials and textures). With camera-based sensing, the real hand achieved a median of 11.5 consecutive successful rotations and a best run of 46. A policy trained without randomization managed a median of zero, even with motion-capture tracking of the block in place of cameras.

A year later the same group had the hand solve a Rubik’s Cube, using automatic domain randomization (ADR), described below. OpenAI reported success in 60% of trials on scrambles needing 15 face rotations and 20% on the hardest scrambles needing 26. Those figures used a cube with built-in sensors to report its face angles, with cameras tracking only its pose. With cameras alone, the paper reported 20% on the 15-rotation scrambles and no successes on the hardest ones. The robot hands article covers the hardware.

Legged locomotion

Locomotion is where the technique became routine.

  • ETH Zurich and ANYmal. A 2019 study combined randomized link masses and centers of mass with an actuator model learned from the real robot. A 2020 follow-up trained a controller that used only joint and inertial sensing and transferred with no real-world training to mud, snow, rubble and vegetation. In 2021, the group trained 4,096 simulated robots in parallel on one GPU, with randomized ground friction, sensor noise and random pushes, and reported flat-terrain walking policies in under four minutes.
  • Google and Minitaur. A 2018 paper combined system identification, an actuator model, simulated latency and randomized dynamics to transfer trotting and galloping gaits.
  • Unitree A1 and RMA. Rapid Motor Adaptation (2021) varied friction, payload, center of mass, motor strength and terrain in simulation and deployed on a Unitree A1 without fine-tuning.

Humanoids

The same recipe now drives humanoid walking. A 2023 study from UC Berkeley trained a transformer controller for Agility Robotics’ Digit in Isaac Gym across randomized dynamics, observation noise, delays and terrain, then deployed it outdoors with no real-world training. The 2025 MuJoCo Playground paper reported the same kind of zero-shot transfer on the Unitree G1, Booster T1 and Berkeley Humanoid. As of November 2026, Unitree’s own open-source training repository for the Go2, H1 and G1 is built on Isaac Lab and tells users to check a trained policy in MuJoCo before running it on the robot.

How to choose randomization ranges

Why too much randomization hurts

A wider range is not free. The policy must find one behavior that works everywhere in the range, and the safest such behavior is usually slow and cautious.

The Minitaur authors put it plainly: dynamics randomization “trades optimality for robustness,” and they chose ranges carefully to avoid overly conservative gaits. A later study on the Laikago quadruped measured the cost: a top speed of about 2.0 mph (0.9 m/s) with randomization against about 2.5 mph (1.1 m/s) without. Its authors found that direct transfer was possible with no dynamics randomization once other design choices were right, and recommended randomizing only parameters that matter.

Training cost rises too. OpenAI reported that its fully randomized hand policy needed about 100 years of simulated experience, against about 3 years without randomization.

A workable rule, offered as the handbook’s editorial judgment: center each range on a measured value, set its width from how uncertain that measurement is, and widen a range only when a real-world failure points to it.

Automatic and adaptive variants

Several methods adjust the ranges during training instead of by hand.

Method How it sets the ranges Needs real-robot data?
Automatic domain randomization (OpenAI, 2019) Starts from one environment; widens a parameter’s bound when the policy does well at that bound, narrows it when the policy does poorly No
Terrain curricula (ETH Zurich, 2020 and 2021) Raises or lowers terrain difficulty according to how well the policy is coping; the 2021 version does this separately for each simulated robot No
Active domain randomization (Mehta et al., 2019) Learns a sampling strategy that favors the most informative variations over uniform sampling No
SimOpt (Chebotar et al., 2018) Shifts the parameter distribution using a few real rollouts interleaved with training Yes, a few rollouts
Bayesian domain randomization, BayRn (Muratore et al., 2020) Uses Bayesian optimization to tune the distribution for performance on the real system Yes, a small amount

Alternatives and complements

Domain randomization is rarely used alone. The table shows how each companion technique relates to it.

Technique What it does Relationship to randomization
System identification Measures the real robot and tunes the simulator to match Narrows the ranges randomization must cover
Learned actuator models Replaces the ideal simulated motor with a model fitted to real actuator data Removes an error that is hard to express as a parameter range
Real-to-sim Builds the simulated scene from scans of the real one, as in the RialTo system Centers training on the actual workspace
Domain adaptation Translates simulated and real images into a shared form Reduces the visual gap that randomization only tolerates
Teacher–student training with privileged information A teacher policy sees simulator-only facts; a student learns to match it from real sensors Lets a policy adapt within the randomized range
Real-world fine-tuning Continues training on a small amount of real data Corrects what simulation got wrong

In teacher–student training, the teacher is given information only a simulator can supply, such as exact friction or terrain shape. A 2019 driving paper, Learning by Cheating, trained a vision-only agent to imitate such a privileged one, and ETH Zurich applied the approach to ANYmal in 2020. RMA is a close relative: its base policy receives an encoding of privileged factors such as friction and payload, and a second module learns to estimate that encoding from about half a second of the robot’s own recent states and actions.

For domain adaptation, the 2019 RCAN method reached 70% grasp success on unseen objects with no real data, almost double what domain randomization alone achieved in that study, and 91% after fine-tuning on 5,000 real grasps.

What to randomize first: a practical checklist

The orderings below are editorial judgment, drawn from which parameters the cited papers randomized.

For a camera-based manipulation policy:

  1. Camera pose and field of view, since a real camera is never mounted exactly where the simulated one is.
  2. Lighting, colors and textures of the table, background and robot.
  3. Object pose, size, mass and friction.
  4. Action and observation delay, including gripper closing time.
  5. Controller gains and joint offsets.
  6. Distractor objects, added once the basic task transfers.

For a legged locomotion policy:

  1. Ground friction.
  2. Payload mass and center of mass.
  3. Motor strength and controller gains, ideally around an actuator model fitted to the real robot.
  4. Latency and sensor noise.
  5. Random pushes to the body.
  6. A terrain curriculum, if the robot will leave flat floors.

In both cases, test the policy in a second simulator before hardware. A policy that fails when the physics engine changes is unlikely to survive the real world.

How current simulators support domain randomization

As of November 2026, the main GPU training frameworks treat randomization as a built-in feature.

Isaac Lab handles it through event terms that run at startup, on each episode reset or at timed intervals. Its documented terms randomize rigid-body mass, inertia, center of mass and friction materials, actuator gains, joint parameters and gravity; push the robot or apply external forces; and randomize visual textures and colors. Observation terms accept a noise model.

MuJoCo Playground ships randomization inside its example environments. Its 2025 paper describes randomized sensor noise, link center of mass, joint offsets, ground friction and payload mass for locomotion, and randomized lighting, colors and camera pose for a camera-based pick task, a vision pipeline the authors called early-stage at the time. Version 1.0, released in November 2026, rebuilt the suite on MuJoCo Warp; its tasks still randomize physics and colors on reset, and the paper’s original JAX environments remain in the repository. The repository also includes system identification and sim-to-real examples.

The robot simulators comparison covers versions, licenses and hardware requirements for both.

Where domain randomization still fails

Randomization varies the parameters of a model. It cannot add physics the model lacks.

  • Contact-rich manipulation. A 2025 review of the reality gap notes that real contact is complex and nonlinear and that simplified contact models produce unstable grasps and slip. If the contact model is wrong in form, no friction range fixes it. Tactile sensing helps the real robot react, but touch sensors are themselves hard to simulate.
  • Deformable objects. Robot training simulations usually assume rigid bodies, the same review notes. Cloth, cables, food and soft packaging behave in ways that a mass or stiffness range does not capture.
  • Perception of real clutter. Random textures taught a detector to find known shapes on a table. Editorial judgment: open-ended scenes with unfamiliar, transparent or reflective objects remain beyond what visual randomization alone delivers. The same review notes that real sensor noise is state-dependent and correlated over time, unlike the simple noise most simulators add.

This is why general-purpose manipulation systems, including vision-language-action models, still depend on real teleoperated demonstrations, with simulation used to add volume and variety.

One limit applies everywhere. A policy that succeeds across every randomized condition in simulation has still only been tested in simulation. Before a pilot moves to production, the numbers that count are measured on hardware. For definitions of the terms used here, see the glossary and the rest of the simulation and data chapter.

Frequently asked questions

What is domain randomization in robotics?

Domain randomization is a way of training a robot policy in simulation while randomly changing the simulator's settings, such as lighting, textures, friction, mass and delays, from one episode to the next. Because the policy never sees the same simulated world twice, it cannot depend on any one setting. If the ranges are chosen well, the real robot behaves like one more variation the policy has already handled.

What is the difference between domain randomization and domain adaptation?

Domain randomization makes the training data varied so the policy tolerates a mismatch between simulation and reality. Domain adaptation tries to remove the mismatch, usually by translating simulated and real images into a shared form or by adapting the model with real data. The two are often combined: the 2019 RCAN method trains on randomized images and learns to map them to one canonical style.

What is automatic domain randomization (ADR)?

Automatic domain randomization is a method OpenAI published in 2019 in its Rubik's Cube work. Training starts in a single, non-randomized environment, and each parameter's range widens automatically when the policy performs well at the edge of the current range and shrinks when it performs poorly. It replaces hand-tuned ranges with a curriculum that grows with the policy.

Can too much domain randomization hurt a robot policy?

Yes. A policy forced to work across an unrealistically wide range of conditions tends to become cautious and slow. A study on the Laikago quadruped measured a lower top speed with dynamics randomization than without it, and OpenAI reported that its fully randomized hand policy needed about 100 years of simulated experience compared with about 3 years without randomization.

Does domain randomization replace system identification?

No. System identification measures the real robot so the simulator can be centered on the right values, and domain randomization then covers the uncertainty that remains. Measuring first lets the ranges be narrower, which generally gives a better-performing policy than randomizing widely around a guess.

Sources

  1. Domain Randomization for Transferring Deep Neural Networks from Simulation to the Real World — Tobin, Fong, Ray, Schneider, Zaremba, Abbeel (OpenAI, UC Berkeley), arXiv:1703.06907
  2. CAD2RL: Real Single-Image Flight without a Single Real Image — Sadeghi and Levine, arXiv:1611.04201
  3. Sim-to-Real Transfer of Robotic Control with Dynamics Randomization — Peng, Andrychowicz, Zaremba, Abbeel (OpenAI, UC Berkeley), arXiv:1710.06537
  4. Learning Dexterous In-Hand Manipulation — OpenAI et al., arXiv:1808.00177
  5. Solving Rubik's Cube with a Robot Hand — OpenAI et al., arXiv:1910.07113
  6. Solving Rubik's Cube with a robot hand — OpenAI (October 15, 2019)
  7. Learning agile and dynamic motor skills for legged robots — Hwangbo et al., Science Robotics, 2019
  8. Learning Quadrupedal Locomotion over Challenging Terrain — Lee, Hwangbo, Wellhausen, Koltun, Hutter, Science Robotics, 2020
  9. RMA: Rapid Motor Adaptation for Legged Robots — Kumar, Fu, Pathak, Malik, arXiv:2107.04034
  10. Real-World Humanoid Locomotion with Reinforcement Learning — Radosavovic et al., arXiv:2303.03381
  11. MuJoCo Playground — Zakka et al., arXiv:2502.08844
  12. MuJoCo Playground repository — Google DeepMind, GitHub
  13. Dynamics Randomization Revisited: A Case Study for Quadrupedal Locomotion — Xie, Da, van de Panne, Babich, Garg, arXiv:2011.02404
  14. Active Domain Randomization — Mehta, Diaz, Golemo, Pal, Paull, arXiv:1904.04762
  15. Data-efficient Domain Randomization with Bayesian Optimization — Muratore, Eilers, Gienger, Peters, arXiv:2003.02471
  16. Learning by Cheating — Chen, Zhou, Koltun, Krähenbühl, CoRL 2019, arXiv:1912.12294
  17. The Reality Gap in Robotics: Challenges, Solutions, and Best Practices — Aljalbout et al., preprint for Annual Review of Control, Robotics, and Autonomous Systems, arXiv:2510.20808
  18. Isaac Lab API reference: isaaclab.envs.mdp (event terms) — NVIDIA and Isaac Lab contributors