For two reasons:
1) Most commonly it is a glancing blow. That is, the vehicle drifts into the guardrail and the guardrail just redirects it, It doesn’t stop the vehicle. A guardrail is unlikely to stop a large truck that hits it at nearly a right angle.
2) The sections of guardrail connected together. So, even when one, or a few posts break, and the guardrail bulges to the side, the guardrail can keep holding the vehicle from going further off the road because the part of the guardrail that moved is still connected to the part ahead (and behind) that is in good shape.
Latest Answers