A sloped armour plate provides better protection than a vertical armour plate of the same thickness. This is due to two reasons. The first is because the sloped armour is wider from a horizontal view than the vertical armour, and thus the shells fired at it will have to travel a greater distance through the armour. The relative thickness can be calculated mathematically, as shown in the two figures below.
While the sloped armour seems superior in terms of relative thickness alone, this does not justify the use of sloped armour to same steel, as the same amount of steel is needed to acheive the same protection. This is because the sloped armour plate will have to be longer to cover the same height. In addition, the other armour plates will have to be larger as well to join up.
The actual bonus comes from the shells deflecting. The more sloped an armour plate is, the more likely it is that the incoming shell will deflect. This is why so many modern-day tanks have almost horizontal frontal armour. One of the most extreme examples is the Swedish Stridsvagn S.
Exactly how likely the shell is the deflect depends on the shell itself - some types even have a soft-metal nose, which will increase effectiveness against sloped armour
(relative thickness) = (thickness) / (sin(angle from horizontal))