500 years into the First Age, Morgoth had become mighty in Middle-earth, not least because of the strife among the Noldor. The mariner Eärendil, wearing the Silmaril on his brow, came to Valinor, the first mortal to set foot there, begging the Valar to help the enslaved Elves and Men of Middle-earth.
The Valar were moved by Eärendil's plea, and along with the Vanyar and Noldor that were in Valinor, riding in the ships of the Teleri, came to Middle-earth in a mighty host. They marched across Beleriand, and met the forces of Morgoth in the plains of Anfauglith.
The Valar and the Elves destroyed the Balrogs, all save a few who fled and hid themselves, and the armies of Orcs likewise. While the Three Houses of Men fought with the Valar, many other Men fought against them and died. Facing defeat, Morgoth released his ultimate weapon, the winged dragons, which had never been seen before, and drove the Valar back.
At that moment Eärendil came with his sky-ship Vingilot, along with the Eagles, and they fought the dragons, in the end slaying Ancalagon the Black, the mightiest of dragons, who broke the towers of Thangorodrim in his fall.
Morgoth was captured hiding in the deepest dungeon of Angband and bound with his old chain Angainor; the two Silmarils still in his possession were taken by the Vala Eönwë and guarded (whence they were later stolen by Maedhros and Maglor). In the end the Valar thrust him "through the Door of Night, beyond the Walls of the World, into the Timeless Void", where he remains.
The wreckage of the war was immense; most of the land west of the Ered Luin was laid waste and soon after sank beneath the waves. Most of the Elves went to the West, while others went East. The Valar raised up the island of Númenor in the Western Sea as a new home for the Edain.