Doriath was the land of the Sindar. It was called the Fenced Land (Dor-iath), for its queen, Melian, put a girdle of enchantment about it, so that nobody could enter without King Thingol's permission.
Doriath was a realm of forests about the great river Sirion, with in it the forests Neldoreth (also Taur-na-Neldor, the northern beech forest), Nivrim (also West-march, an oak forest), and Region (pronounced Reh-gi-on, the main forest). Additionally, the forests of Brethil and Nan Elmoth were held as part of Doriath, but these last two lay outside the Girdle of Melian. King Elu Thingol of Doriath, also High King of the Sindar, saw all of Beleriand as his realm, from the Gelion to Belegaer.
The Vanyar and Ñoldor had passed by it on the Great Journey, and had been ferried across on Tol Eressëa by the time the Teleri arrived. Then their lord Elwë was lost in Nan Elmoth, and when Ulmo returned for them a part remained behind. They became known as the Sindar or Grey Elves, and when Thingol returned he became their king, ruling from Doriath.
Doriath was originally named Eglador, meaning either "Land of the Forsaken" or "Land of the Elves", but in the last years before the First Age attacks by Melkor's creatures (Orcs) began to increase in Beleriand, and Melian fenced the forests of Neldoreth, Region, and Nivrim. Thingol then called all the Sindar to Doriath, but many remained in the wild. After the First Battle of Beleriand, many Laiquendi removed to Doriath.
When the Ñoldor returned to Middle-earth at the beginning of the First Age, Thingol refused to allow them in Doriath, with the exception of the children of Finarfin, who were related to him by his brother Olwë.
Beren, son of Barahir and lord of the First House of Men, passed through the Girdle as Melian had foretold, and arrived in Neldoreth. There Thingol's daughter Lúthien fell in love with him. After the Quest for the Silmaril the Wolf Carcharoth also breached the Girdle, but Thingol, Beren, and Thingol's captains Beleg and Mablung hunted and killed the beast.
Húrin brought the treasure of Nargothrond to Doriath after the fall of Finrod's realm, and Thingol enlisted the Dwarves of Nogrod to combine the Silmaril of Beren and Lúthien with the Nauglamír, the Dwarves' Necklace. The Dwarves then attacked Thingol, and slew him, stealing the necklace, during the first Sack of Doriath. Melian then left, and with her the protective Girdle.
Doriath was briefly restored under Beren and Lúthien's son Dior, but he was attacked and killed by the sons of Fëanor in the Second Kinslaying. Afterwards Doriath remained abandoned until it was sunk along with most of the rest of Beleriand.