One of the earliest known examples of a hair accessory is that of a diadem worn by the Priest King of the Indus Valley Civilization circa 2200-2600 BC. Since then, hair accessories of all shapes and sizes have been used for fashion, function and symbolic purposes all throughout history and up to the present.
One example of a hair accessory with ancient origins still seeing modern use is the turban, depicted on Mesopotamian sculptures dating as far back as 2350 BC. Historically, the turban has been used as a symbol of royalty, spirituality, dignity, self-respect and courage. Functionally, it has also served as protection from the elements for the wearer. Today, turbans are primarily associated with Muslim and Sikh culture. In the past they were also worn by Hindus, Christians, and Jews across Europe and Africa.
As time went on, the idea of hair accessories as a symbol would continue to appear in various cultures around the world, such as with the Greek wreath and the Japanese hachimaki. In ancient Greece, the wreath was the accessory of choice used by people to mark special occasions and signify important figures. For example, winners of the ancient olympics were donned with a wreath and Greek gods were often depicted wearing wreaths. On the other hand, in feudal Japan, the hachimaki--a simple cloth tied around the forehead--was used by Samurai to help make their helmets more comfortable to wear. Over time it came to be seen as a symbol of perseverance and courage, usually with an inspirational slogan written on the front.
Flashing forward to the 20th century, headbands in particular saw a resurgence in use thanks to the flapper movement, a generation of young women rebelling against cultural norms. Celebrity actresses, such as Audrey Hepburn and Grace Kelly, joining in on the trend and wearing headbands in films helped to further boost the appeal of headbands. In recent times, it's still common to see movie stars and pro athletes wearing hair accessories, whether it be for fashion or function, keeping them in vogue.