Fulfilling the promise given to his father, King Dasaratha, Rama along with Seeta and Lakshmana went in exile. They lived their ascetic lives blissfully in the forest and the fourteen year exile was drawing to a close when Ravana, the king of Lanka, having heard much of Seetha's beauty and desiring to possess her, used cunning means and carried her away.
Rama, when he discovered Seeta's absence, was inconsolable. With Lakshmana's mature advice and help, they began their search for Seeta. Fortunately, she had been noticed being carried away by many and the brothers took this trail until they reached Kishkindha, the abode of the Vanaras.
Here, they befriended Sugreeva and helped him ascend the throne. Sugreeva, in return, promised all help to find Seeta. Rama was shown a small bundle of jewels that was described by Sugreeva's men as having fallen from the sky. Rama instantly recognized them as Seeta's.
Hanuman was Sugreeva's generalissimo. Earlier he had saved Sugreeva from a mad elephant by holding it by its trunk and flinging it away, earning him the position he held presently. Sugreeva's army was divided in four and each battalion went in each of the four directions. Hanuman, instinctively, opted to go south with his men
He reached the southern shores of Bharata and there he learnt that Ravana of Lanka had carried Seeta away to the island in a flying chariot. He stood atop a mountain, said his prayers to his father, Vayu, and with a roar that shook the earth, leaped across the ocean. He landed safe in Lanka but not before vanquishing a terrible sea-monster en-route.
In beautiful Lanka, bearing all the insignia of a flourishing kingdom, Hanuman wandered in the guise of a little monkey. He went hither and thither looking carefully at each woman to see if she was Seeta. Finally, having looked in the houses and the market places, in the palaces and in the harems, Hanuman reached a garden called Ashokavana.
Here he found a beautiful woman humming sad sweet notes. Upon moving closer, he understood that she was pining for her Lord to come and take her back. Understanding that she was none other than Seeta, he looked about to find if somebody was watching and seeing none, sprang up before her, startling her. He held his palms together and paid obeisance to her. To assure her that he was there on a mission for Rama, he showed her Rama's ring which he had carried along.
Although Hanuman was powerful enough to carry Seeta and a hundred others like her together back with him, he yielded to Seeta's wish that Rama come and fight Ravana, liberate all those that were unjustly held there and then take her back.
Hanuman was wise by Brahma's boon. He knew that war begets only sorrow even for the victor. He desired a peaceful settlement. With this intent he went to Ravana's court, introduced himself and sought peace. A haughty Ravana and his misled men laughed at the sight of a mere monkey being the ambassador for peace.
Ravana sat on the throne set at an elevated level. Simply to exhibit to Ravana that he was not pitted against somebody that could be crushed, Hanuman coiled up his tail so high that it was higher than Ravana's throne and sat upon it. Ravana was angered and ordered his men to set this audacious monkey's tail on fire.
The men set Hanuman's tail on fire. Exclaiming that the heat of the fire was nothing but the angst of Mother Seeta, Hanuman went all over Lanka and set everything on fire. With Lanka burning, Hanuman went to the ocean and dipped in his tail, thereby extinguishing the fire.
He now returned to Rama with the promising news of Seeta's presence in Lanka.