In the time before even legends recall, demons1 discovered space flight.
Space flight involves exposing aerstone to mana. When exposed to mana, the aerstone moves towards it. As more mana is exposed, the aerstone moves faster. The demons developed methods to gather and store mana in materia. This allowed continual and controlled exposure of mana to aerstone.
After an amount of exposure to mana, aerstone's internal structure organizes and the aerstone becomes sentient2. Sentient aerstones are able to project illusions and sense their surroundings3.
A sentient aerstone no longer needs mana exposure since it has a will of its own.
In their exploration, Demons discovered the other races and enslaved them. Demons used members of each race in different areas of their society across all the worlds in their empire. Elves were used in scholarly pursuits. Dwarves were used for manufacture, Goblins were bookkeepers, Orcs were security, Humans filled in the gaps that were left.4
Eventually the immense amounts of mana needed for space travel were depleted by overuse. Knowing the mana levels were decreasing, the Demons built giant artificial superstructures throughout the galaxy to keep themselves in stasis until mana levels had returned to sufficient levels to support their empire. The Demons also removed all of their technology from subjugated worlds in an attempt to keep their empire stabilized as much as possible. Their plan was that without the technology and mana, the subjugate species would not be able to travel space or develop new technologies.
They also set up tombs on various key worlds that will awaken them periodically so they can keep a closer eye on those worlds. They included materia in these tombs so that their watchers could use magic if needed.
The tomb on one world, Izus, malfunctioned and the demons never awakened. This malfunction was actually sabotage. A group of Elves and Dwarves, realizing what was happening and seeing a chance to finally overthrow the Demons set up a secret society on Izus that kept a true record of who and what the Demons are.
During the intervening time. Being completely cut off from each other, practically every world relegates Demons to myth, even the secret society on Izus.
As mana slowly regenerates, magic becomes possible again
Izusian Dwarves discover the malfunctioning tomb. The Izusians realize that the Demons were real and begin reexamining the old legends. After piecing together what happened, the Izusians begin working on a plan to keep the Demons from regaining their empire. Part of this involves developing a newer more efficient form of space travel so that the worlds can begin reconnecting before the Demons awake.
Additional Ideas (2)
Although the Izusians are the only ones that planned it, there have been a few other worlds that managed to regain space flight. These other worlds were not key worlds that the chose to Demons leave tombs on.
The Tomb Worlds
The tomb worlds have had regular harassment by the Demons and have not progressed magitechnologically. However, those worlds are important to the Izusians and everyone else that wishes to resist the Demons. Not only do those worlds contain stashes of Demon technology, but the inhabitants have a more recent memory of the Demons and their tactics.
Everyone in space is looking to rediscover Demon technology. When a citadel (the megastructures that Demons built in space) is discovered it is generally scuttled for the technology, but great care must be taken during the early stages of the process, otherwise the citadel will awaken the Demons.
Ancient tales speak of a war between the Demons and Angels. Modern magiscientists are not sure who or what the Angels might be, or even of the tales are in any way accurate.