The Caves of Hercules is an archaeological cave complex located in Cape Spartel, Morocco. 
 Situated 14 kilometres (9 mi) west of Tangier, the popular tourist attraction is adjacent to the summer palace of the King of Morocco.
 The cave has two openings, one to the sea and one to land. The sea opening is known as "The Map of Africa." It is believed that the Phoenicians created the sea opening, which is in the shape of Africa when looked at from the sea. There are also some markings on the wall in the shape of eyes, that are said to have been made by the Phoenicians, which make up a map of the local area.[citation needed]
 The cave itself is part natural and part man-made. The man-made part was used by Berber people to cut stone wheels from the walls, to make millstones, thus expanding the cave considerably. 
 The cave was long thought to be bottomless. It was believed that the cave is one end of a subterranean ley tunnel over 24 kilometres (15 mi) long which passes under the Strait of Gibraltar and emerges at St. Michael's Cave in Gibraltar. Legend has it that the Barbary macaques came to the Rock of Gibraltar from Morocco this way.
 Mythological tradition also holds that the Greek god Heracles stayed and slept in this cave before doing his 11th labour, (one of the 12 labours which King Eurystheus of Tiryns had given to him) which was to get golden apples from the Hesperides Garden, which some ancient Greek writers said was located nearby at Lixus (one of the cities of Larache) .
 According to some Roman sources, while on his way to the garden of the Hesperides, Hercules had to cross the mountain that was once Atlas. Instead of climbing the great mountain, Hercules used his superhuman strength to smash through it. By doing so, he connected the Atlantic Ocean to the Mediterranean Sea and formed the Strait of Gibraltar. One part of the split mountain is Gibraltar and the other is either Monte Hacho in Ceuta or Jebel Musa (known as the Mons Abyla in classical times) in Morocco. These two mountains taken together have since then been known as the Pillars of Hercules, though other natural features have been associated with the name. Diodorus Siculus, however, held that instead of smashing through an isthmus to create the Straits of Gibraltar, Hercules narrowed an already existing strait to prevent monsters from the Atlantic Ocean from entering the Mediterranean Sea.
 The Greek mythology version is that Heracles went to Atlas and offered to hold up the heavens while Atlas got the apples from the garden of his daughters, the Hesperides which was also guarded by the dragon Ladon. Upon his return with the apples, however, Atlas attempted to trick Heracles into carrying the sky permanently by offering to deliver the apples himself, as anyone who purposely took the burden must carry it forever, or until someone else took it away. Heracles, suspecting Atlas did not intend to return, pretended to agree to Atlas' offer, asking only that Atlas take the sky again for a few minutes so Heracles could rearrange his cloak as padding on his shoulders. When Atlas set down the apples and took the heavens upon his shoulders again, Heracles took the apples and ran away.
 In 6000 BC, the Caves of Hercules were inhabited by Neolithic people.
 In 1920, the caves were officially opened to the public. They were declared a National Heritage site in 1952. In 1982, electric lights were installed in the caves. 
 In 1986, the ashes of Brion Gysin, a renowned artist and writer, were scattered in the caves.
 On October 23, 1995, British rock group Def Leppard played a concert in the cave (along with concerts in London and Vancouver, Canada), thereby becoming the first rock group to play three concerts on three continents in one day. The achievement was certified by the Guinness Book of World Records.
 On 20 December 2003, the caves were closed to the public due to a rockfall caused by nearby construction work, necessitating repairs and ensuring visitor safety. In January 2004, the caves were reopened to the public. In October 2015, the caves reopened after a renovation commissioned by King Mohammed VI.