Two millennia prior to the series' events, the humans create black-blooded androids to accomplish tasks to facilitate their lives. However, these androids rebel against the humankind; to destroy the black-bloodeds, the red-blooded humans create the . In the aftermath, the are almost extinct, and the hide themselves from the machines. , a red-blooded, , a black-blooded, , a machine—collectively known as —create the to gather the wishes of its wielders, the seven , who by fusing with the Gojin-zou gain supernatural powers to fight against the machines, whose wishes are also stored into the Gojin-zou when they are destroyed. By combining these wishes with the Kami's red blood, a machine known as "Spider's Thread" will guarantee any wish—the magi hope the wish that will be fulfilled is to return the world to how it was before the war.
