It states in Megillas Esther that when the Yidden heard Haman's evil decree, there was (4:3) צום ובכי ומספד, fasting, crying, and eulogies. The Alshich points out that a hesped, eulogy, is said on others. No one says a hesped on himself. He explains that each person was crying for his fellow man. They weren't only worried for themselves but also about their friends' fate. They cried, "If Haman succeeds with his evil decree, what will be with our neighbors and friends?" This compassion brought salvation.
It states (Tehillim 121:5) ה' צלך, "Hashem is your shadow." The Midrash teaches that just as a shadow mimics what a person does, ה' צלך means Hashem mimics what people do. The Alshich HaKadosh (quoted in Arvei Nachal, Mikeitz, Drush 1, ד"ה ואמנם) teaches that Mordechai and Esther cared for one another, and they helped one another. This aroused Hashem to act accordingly, to care and have compassion for the Jewish nation.
The Alshich writes, "Mordechai didn't think about what he could gain, rather what Esther could gain. When he heard Bigson and Seresh plotting to kill Achashverosh, he knew that whoever saved the king would receive a grand reward. So, Mordechai told Esther about the plot. [He wanted her to be rewarded.] But Esther wanted Mordechai to get the credit, so she told Achashverosh in the name of Mordechai. It states (Esther 2:22) ויודע הדבר למרדכי ויגד לאסתר המכלה ותאמר אסתר למלך בשם מרדכי, 'The matter became known to Mordechai, and he told it to Queen Esther, and Esther told to the king in Mordecai's name.' They were both trying to help each other, and in the merit of their selfless caring for one another, Hashem saved them and the entire Jewish nation".
It states in the megillah (2:11), ובכל יום ויום מרדכי מתהלך לפני חצר בית הנשים לדעת את שלום אסתר, "Day after day, Mordechai would walk in front of the courtyard of the house of women to know about Esther's well-being and what would become of her." The Sfas Emes (7637) writes, "Everything written in the megillah is part of the miracle. For four or five years, when Esther was taken by the goyim, Mordechai HaTzaddik would go every day to see how she was doing, for she was an orphan, captured among the goyim. This is certainly part of the miracle. We merited the miracle thanks to Mordechai's concern for Esther." This is as we are explaining. When one shows concern for his fellow man, Hashem acts similarly towards the Jewish nation. This attitude brought the salvation.
Haman said (Esther 3:8), ישנו עם אחד מפוזר ומפורד, "There is a nation scattered about and dispersed..." Tzaddikim said that Haman's primary strategy to harm the Yidden was to cause separation among them. In response, Esther told Mordechai (4:16), לך כנוס את כל היהודים, "Go gather all the Yidden." The unity of Bnei Yisrael and their caring for one another saved them.
The Kedushas Levi (beginning of Kedushah Rishonah) writes, "Purim has three mitzvos which aren't found by any other yom tov: (1) reading the megillah, (2) matanos l'evyonim, and (3) mishloach manos. The fourth mitzvah – to celebrate with a festive meal is performed every yom tov." The commentaries explain that the purpose of matanos l'evyonim and mishloach manos is to increase peace and love among Yidden. We have these mitzvos on Purim because it was love and peace that brought about salvation.