Gymnasium: A Standard Interface for Reinforcement Learning Environments

Gymnasium: A Standard Interface for Reinforcement Learning Environments

Featured

Farama Foundation, Jordan Terry, Mark Towers, Benjamin Black, Manuel Goulão, Andrea PI Annovazzi, Sami Jullien, Katherine Crowson, Jake Forsey, Sander Schulhoff, Ariel Kwiatkowski · Farama Foundation · 2023

Framework

Pure Python + optional PyTorch/JAX bindings

License

MIT

Stars

11,943

Summary

Gymnasium is the maintained successor to OpenAI Gym, providing a standardized API for RL environments with 100+ built-in tasks, vectorized parallel execution, and native support for physics engines like MuJoCo, PyBullet, and IsaacGym.

Abstract Summary

Gymnasium is the universal interface for reinforcement learning environments. Originally a fork of OpenAI Gym (which was unmaintained after 2021), Gymnasium is now the standard API used by virtually every RL library: Stable Baselines3, RLlib, CleanRL, Tianshou, and hundreds of research codebases. The `env.step(action)` → `obs, reward, terminated, truncated, info` API is so ubiquitous that any new environment or algorithm is expected to support it. Gymnasium ships with 100+ built-in environments: classic control (CartPole, Pendulum), box2d physics (LunarLander, CarRacing), Atari (via ALE), MuJoCo robotics (HalfCheetah, Ant, Humanoid), and third-party environments via the Gymnasium API. The 1.0 release adds vectorized environments (`AsyncVectorEnv`, `SyncVectorEnv`) that run 1000+ parallel episodes on multi-core CPUs, plus first-class wrappers for observation normalization, frame stacking, and reward clipping. The ecosystem is vast: `gymnasium-robotics` adds dexterous manipulation tasks (Shadow Hand, Fetch), `gymnasium-mujoco` provides advanced physics, and `shimmy` translates DeepMind, PettingZoo, and other APIs to Gymnasium. This standardization means that any RL algorithm written for Gymnasium works on any compatible environment with zero code changes—a huge productivity boost for research. For robotics specifically, Gymnasium is the integration layer: IsaacGym, MuJoCo, PyBullet, and SAPIEN all provide Gymnasium-compatible wrappers, so you can prototype a policy in a simple CartPole environment and deploy it to a humanoid robot with only environment ID changes. The `RecordVideo` and `RecordEpisodeStatistics` wrappers make experiment tracking and visualization trivial.

Key Points

  • Standard RL API: env.step(action) → obs, reward, terminated, truncated, info.
  • 100+ built-in environments: classic control, Atari, MuJoCo, box2d.
  • Vectorized execution: 1000+ parallel envs on CPU.
  • Ecosystem: robotics, MuJoCo, DeepMind, PettingZoo integrations.
  • Drop-in replacement for OpenAI Gym with active maintenance.
Share

Related Papers

Eureka: Human-Level Reward Design via Coding Large Language Models

Eureka: Human-Level Reward Design via Coding Large Language Models

Yecheng Jason Ma, William Liang, Guanzhi Wang et al. · ICLR 2024 (Oral) · May 2024

Eureka uses GPT-4 to write reward functions for RL environments, achieving human-level reward design on 29 tasks and enabling zero-shot sim-to-real transfer on Shadow Hand dexterous manipulation.

rl foundation-models sim-to-real
Code PDF Intermediate
GitHub ★ 3,161 Code updated: May 2026
ManiSkill: A Unified Benchmark for Generalizable Manipulation Skills

ManiSkill: A Unified Benchmark for Generalizable Manipulation Skills

Jiayuan Gu, Sean Xiang, Stone Tao et al. · ICLR 2023 (Oral) · Jan 2023

ManiSkill is a GPU-parallelized robotics simulation benchmark with 20+ manipulation tasks, PartNet-Mobility assets, and unified observation/action spaces, supporting RL, IL, and VLA training at millions of steps per hour.

sim-to-real rl manipulation foundation-models
Code PDF Beginner
GitHub ★ 2,914 Code updated: May 2026