The main purpose of installation of shear keys is to increase the extra passive resistance developed by the height of shear keys. However, active pressure developed by shear keys also increases simultaneously.
The success of shear keys lies in the fact that the increase of passive pressure exceeds the increase in active pressure, resulting in a net improvement of sliding resistance.
When structure is failing in Sliding criteria during the stability check due to large horizontal forces on the column , Shear key is provided during construction joint of column to stop the sliding of column from joint there by increasing factor of safety for sliding.