What is PPO and Why Is It the Default RL Algorithm?
The problem PPO solves: one bad step can kill a policy
Policy-gradient methods learn by nudging the policy toward actions that got good returns. The danger is the size of the nudge. A gradient step that looks good on the current batch can move the policy into a region where it behaves terribly — and once the policy is bad, the data it collects is bad too, so the next update is computed from garbage. Vanilla REINFORCE had this failure mode constantly: a run could be improving for hours and then fall off a cliff in one update, never to recover. The field's answer in 2015 was TRPO (Trust Region Policy Optimization), which constrained each update to a small KL-divergence trust region around the old policy. TRPO worked — but it needed conjugate gradients and second-order approximations, which made it fiddly to implement and slow to run.
PPO's insight, in the 2017 paper, was that you could get almost all of TRPO's stability with a trick a first-year could implement: clip the update. No trust region to solve, no Fisher information matrix, no conjugate gradient — just a min and a clamp. The paper tested it on MuJoCo locomotion, Atari, and Roboschool, and it beat TRPO and the vanilla baselines on most of them while running about three times faster than TRPO. A 12-page engineering note quietly became the most-used algorithm in the field.
The clip, in plain English
Here is the whole mechanism, with no equations you cannot read. For each state-action pair in the batch, PPO computes two numbers:
- The ratio r — how much more likely the new policy is to take this action than the old policy was. At the start of an update r = 1. If the new policy favors the action, r > 1; if it avoids it, r < 1.
- The advantage A — whether this action turned out better or worse than average in this state. Positive means “do more of this,” negative means “do less.”
The unclipped objective is just r × A: move toward good actions, away from bad ones. The clipped version first clamps r into [1 − ε, 1 + ε] — with the paper's ε = 0.2, that is [0.8, 1.2] — and then takes the minimum of the clipped and unclipped versions. The min is the pessimistic part, and it is the whole point:
- If the advantage is positive and the update wants r = 1.5, the clip caps the credit at 1.2. The policy still moves toward the action — it just cannot sprint there in one step.
- If the advantage is negative and the update wants r = 0.3, the clip again caps the move, so the policy cannot flee from a bad action so fast it forgets everything else it knew.
- Because it is a min, the objective never rewards moving past the clip in either direction. The update is bounded, by construction, on every single step.
That is it. One hyperparameter, ε, controls the size of the trust region, and the paper found 0.1 to 0.3 all work, with 0.2 the sweet spot. The second PPO variant in the paper — a KL-divergence penalty with an adaptive coefficient — performed worse in the ablations and is the one nobody uses. When people say “PPO” today, they mean PPO-Clip.
The defaults that became the defaults
Part of PPO's dominance is that the defaults stopped being a choice. The paper's hyperparameters, with small modifications, are still the recommended starting point in nearly every implementation, and Stable-Baselines3 — the library most first agents are built with — ships them as its defaults:
| Hyperparameter | SB3 default | What it does |
|---|---|---|
| Clip range (ε) | 0.2 | How far the policy may move per update |
| Learning rate | 3e-4 | Step size for the optimizer (Adam) |
| Rollout length (n_steps) | 2048 | Environment steps collected before each update |
| Epochs per update (n_epochs) | 10 | How many passes over the same batch |
| Discount (γ) | 0.99 | How much the future matters |
| GAE lambda (λ) | 0.95 | Bias-variance trade-off in advantage estimation |
| Value coefficient | 0.5 | Weight of the critic's loss vs the policy's |
| Entropy coefficient | 0.0 | Bonus for keeping the policy exploratory |
Notice what is missing: there is no temperature to anneal, no target network to tune, no replay buffer to size. A first-timer can copy these numbers, change the environment name, and get a learning curve. That is not a small thing. Most algorithms in RL have a “works on the paper's tasks, falls apart on yours” problem; PPO's defaults transfer because the clip absorbs the mistakes the defaults would otherwise punish. Our first-timer's recipe runs exactly this configuration on CartPole, and the five bugs that stop most first agents are all in the setup around the algorithm, not in PPO itself.
Why it became the default: four compounding reasons
1. It is stable. The failure mode that killed vanilla policy gradient — the single catastrophic update — is structurally impossible in PPO-Clip, because the objective stops rewarding movement past the clip. Runs still fail, but they fail slowly and diagnosably: flat learning curves, not cliffs. When you are paying for compute by the hour, a slow failure beats a sudden one.
2. It is simple. The core idea is a min and a clamp, and a clean implementation is about a hundred lines. Every framework ships one — Stable-Baselines3, CleanRL, Tianshou, RLlib — and they mostly agree, because there is so little to disagree about. Simplicity is also why it is the algorithm tutorials teach first: you can explain the whole thing in a paragraph, which is exactly what this post just did.
3. It is forgiving. The paper's sweep showed performance moving only a few percent as ε varied from 0.1 to 0.3, and the SB3 defaults work across classic control, Atari, and MuJoCo without per-task tuning. In a field where a wrong learning rate can silently produce a flat line, an algorithm that works with the defaults is an algorithm people actually finish projects with.
4. It conquered a second field. InstructGPT (2022) used PPO for the RL step of RLHF, and ChatGPT inherited it — which meant every lab aligning a language model needed a PPO implementation, a PPO codebase, and PPO expertise. That is a strange historical accident (nothing about language models particularly suits PPO), but it made PPO the default in LLM training too, and the tooling, tutorials, and tribal knowledge followed the money. GRPO, the critic-free descendant that now dominates RLVR, is best understood as PPO with the value network removed and the group as the baseline — it is still the same family, nine years on.
When PPO is the wrong tool
A default is a starting point, not a law, and PPO has real weaknesses worth knowing before you commit a budget to it. The biggest is sample efficiency: because it is on-policy, it throws away each batch after a few epochs, so it needs far more environment steps than off-policy algorithms like SAC or TD3 to reach the same performance on continuous control. If each environment step costs real money — a physical robot, an expensive simulator, a human in the loop — an off-policy method will squeeze more learning out of every step, and PPO's stability will not compensate for a budget that runs out first.
The second is the critic. PPO is an actor-critic method: it needs a value network to estimate advantages, and that network is a second thing to train, tune, and debug. In LLM training, the value network is as large as the policy itself — double the memory, double the failure surface — which is exactly why GRPO drops it and why RLVR in 2026 runs on GRPO, not PPO. (The details are in our GRPO guide, and the reward-model side of RLHF in our reward-model guide.)
And the third is honesty about what “default” means: PPO wins on robustness, not on peak performance. On a fixed sample budget with a tuned competitor, it will usually lose. The reason to start with PPO is that you do not yet know whether your problem is a tuning problem or a problem problem — and PPO is the fastest way to find out, because it removes the algorithm from the list of suspects. If PPO learns nothing, the reward, the observation, or the environment is broken. That diagnostic value is, quietly, the best reason to keep it first.
How to try it yourself
- Run the defaults: the first-timer's recipe trains CartPole with PPO in an afternoon on a laptop CPU — the classic control category in the directory is where it starts, and LunarLander is the natural second task.
- See the clip earn its keep: the Atari category is where vanilla policy gradient used to collapse and PPO holds steady — same algorithm, same defaults, pixel observations.
- Try the continuous-control home turf: MuJoCo locomotion is where the PPO paper beat TRPO, and where SAC will beat PPO on sample efficiency if you want to feel the trade-off yourself.
- Follow the family line: GRPO is PPO's critic-free descendant for LLM training, RLHF vs RLVR vs DPO is where PPO sits in the alignment stack, and the GPU guide tells you what hardware any of this actually needs.
Frequently asked questions
What does PPO stand for?
Proximal Policy Optimization, introduced by Schulman, Wolski, Dhariwal, Radford, and Klimov at OpenAI in 2017 (arXiv:1707.06347). "Proximal" means the new policy stays proximal — close — to the old one: each update is limited so the policy can only move a small, safe distance from the policy that collected the data. The name is the whole idea: optimize, but stay near where you were.
Why is PPO the default RL algorithm?
Four reasons, and they compound. It is stable: the clip stops the one catastrophic update that used to destroy a policy-gradient run. It is simple: the core idea fits in a few lines and the whole algorithm in about a hundred, so every library ships a good one. It is forgiving: the paper's defaults (clip 0.2, learning rate 3e-4) work across CartPole, Atari, and MuJoCo with almost no tuning. And it is everywhere: it was the algorithm behind RLHF in InstructGPT and ChatGPT, so every framework, tutorial, and codebase already has a PPO implementation lying around. Defaults become defaults because switching costs more than staying.
What does the clip in PPO actually do?
Each update computes a ratio r: how much more (or less) likely the new policy is to take an action than the old policy was. PPO multiplies that ratio by the advantage, then clips the ratio into [0.8, 1.2] with epsilon 0.2 and takes the minimum of the clipped and unclipped versions. If an update would push the policy far in a direction the data says is good, the clip stops rewarding it past 20%; if the data says an action is bad, the clip stops the policy from fleeing from it too fast. The min makes the objective pessimistic on purpose: the algorithm only trusts improvements it can make without moving far.
Is PPO on-policy or off-policy?
On-policy. PPO trains only on data collected by the current policy, and throws that data away after a few epochs of updates — typically 10 passes over the same batch, then it is gone. That is the price of the stability: it cannot reuse old experience the way off-policy algorithms like SAC or DQN can, so it needs more environment steps to reach the same performance. In practice the trade is worth it for most people, because environment steps are cheap and a collapsed run is expensive.
When should I not use PPO?
When sample efficiency is the binding constraint — if each environment step costs real money or real robot time, an off-policy algorithm like SAC (continuous control) or a model-based method will squeeze more learning out of every step. And in LLM training, PPO's critic network has largely been replaced: GRPO drops the value network entirely and compares answers within a group, which is why it, not PPO, is the standard for RLVR on reasoning models in 2026. PPO is still the right first algorithm and the right default for almost everything else — but a default is a starting point, not a law.
What do you think?
When did PPO save a run for you — or when did you switch away from it, and to what? Tell us the task, the algorithm you replaced it with, and whether the switch was worth it; the best answers get featured in a future briefing.
The lab notebook is rlenvlab’s blog — guides and the daily RL Briefing on the environments ecosystem. More from the lab notebook →