Ted Heath in the UK, Mrs Bandarnaike in Sri Lanka and Mujibur Rahman in Bangladesh had all declared Emergency. Heath failed in his struggle with the coal miners but Indira's Emergency was an immediate success. Foreign criticism was muted- and did not matter in any case because the Soviet Union backed Indira to the hilt. Willy Brandt was a joke figure who had to resign in 1974 because a close aide of his was discovered to be a Stasi agent.
Mujib's assassination strengthened Indira's paranoia that the CIA was out to get her by fair means or foul. She was also suspicious of the role of the R.S.S because her minions would declare that anyone they didn't like, or who was in their way, was a 'hard core Sanghi'. On the other hand, the RSS leadership itself was sending her signals that they would support her 'constructive' program. In other words, Indira believed that they could always be won over because they genuinely admired her role in liberating Bangladesh.
Why did Indira suddenly lift the Emergency? The answer is that her son, Sanjay, and his minions had taken over the party. What if they arranged an 'accident' for her so as to take over the whole country? After all, Sanjay- like the rest of Congress- needed Indira as their biggest 'vote-catcher'. They could still get those votes thanks to a 'sympathy wave' (as happened to Rajiv Gandhi after his mother's death) and once entrenched in power could use corrupt and criminal means to perpetuate their reign.
Indira needed to show Sanjay and his coterie that they could not carry the country on their own. Their power derived from her popularity. Moreover, if Indira lost and had to spend a couple of years in Opposition, then the Janata Morcha coalition would collapse- in fact this is exactly what happened- so she would return with an even firmer grip on power.
Sanjay Gandhi was useful to his mother for two reasons- firstly, he could do corrupt deals with anybody, because he had no ideology. Secondly, people would support Indira simply as a check on Sanjay. Sanjay Gandhi's death changed the equation. Indira appeared rudderless and committed some great blunders before her bodyguards finally gunned her down. Autocracy, it seems, is easily tempered by Assassination.