Kalyan Singh became Chief Minister of Uttar Pradesh for the second time in September 1997, taking the post over from Mayawati as part of their power-sharing agreement.
In February 1998, his government withdrew cases against those accused in the Babri Masjid demolition, stating that a Ram temple would be built at the site if the BJP were to take power in Delhi.The BSP and BJP came into conflict over the policies that the BSP government had implemented targeting Dalit social welfare.On 21 October 1997 the BSP withdrew support for Singh's government.
Singh's administration ended many of the BSP's Dalit-focused programmes soon after taking office.
Bhandari invited Jagdambika Pal of the INC to form a new government, in which Agrawal became deputy chief minister.Bhandari's order was stayed by a division bench of the Allahabad High Court, which reinstated Singh's administration two days after its dismissal.
However, he began to be seen as a "patron of the backward castes" by upper-caste members of his own party, and to face opposition as a result.