Around 600 AD, waves of invaders were sweeping across Europe, plunging the region into a period of decline known as the Middle Ages. During this time, Europe was a fragmented collection of small kingdoms. One of the most powerful to emerge was the Frankish kingdom, established by Clovis in the 5th century. In the 800s, Charlemagne united much of Western Europe under the Carolingian Empire and revived classical learning, but the empire fragmented after his death. Europe was later invaded by Vikings, Magyars, and Muslims, threatening the survival of fledgling states.