MEGALOVANIA

"MEGALOVANIA" (/ˌmɛ.gʌ.loʊ.ˈveɪ.niː.ə/) is the 100th track in the Undertale Soundtrack. It is a fast-paced song which plays during the final battle against Sans on the Genocide Route.

History
"Megalovania" was originally composed for Toby Fox's hack of EarthBound known as "Radiation's Halloween Hack" which was a submission to Starmen.Net's 2008 Halloween Funfest. The original song from the EarthBound Halloween Hack can be found here.

"Radiation's Halloween Hack" was about an alternate universe of EarthBound where the chosen four never returned, or simply put "bad rom hack with swears". According to "The Making of Radiation's Halloween Hack", the track "Megalomania" from Live A Live was originally planned to be used as the game's final boss theme instead. Toby Fox never got around to it, so he "yelled whatever [he] felt like into a microphone and copied it down", thus creating "Megalovania." Toby Fox has also hinted that Megalovania was also inspired by "Gadobadorrer" from Brandish 2: The Planet Buster, where the hack's protagonist originated from.

This song would later be reused for the webcomic, Homestuck, as "MeGaLoVania" on the Homestuck Vol. 6: Heir Transparent album with guitars from Joren "Tensei" de Bruin. This version makes a brief appearance in the Trickster Mode of "[S] Past Karkat: Wake up." and then makes a full appearance in " [S Wake."] This track's lietmotif can also be heard in the AlterniaBound bonus track, "The Blind Prophet", another track by Toby Fox.

Trivia

 * The word "Megalovania" is a combination of "Megalomania" and "Transylvania".
 * "Megalomania" is the boss theme from the game Live A Live, which served as an inspiration for "Megalovania". Though Megalovania doesn't directly quote Megalomania's melody, it has a similar feeling and structure. In real life, megalomania is the delusion of being vastly more important and powerful than one really is.
 * The word Transylvania was jammed into the name to give it a feeling reminiscent of Halloween.
 * Toby Fox's mother calls MEGALOVANIA 'MEGALAVEGALA'.
 * A popular theory among fans is that MEGALOVANIA is the theme for the Player/Chara/Frisk, and not Sans, and that instead of the player fighting Sans, Sans is fighting the player. Evidence of this includes:
 * The fact that Sans attacks first, dodges every attack, and can perform an off-guard kill on the player once they are convinced into no longer fighting, all of which the player is capable of doing themselves but not other enemies.
 * While most major characters in the game's battle themes are variations of or incorporate their leitmotif or at least are used in another context somewhat relating to the character, MEGALOVANIA has no trace of Sans' own leitmotif used in other songs such as "sans.", "It's Raining Somewhere Else", and the unused "Song That Might Play When You Fight Sans" and is otherwise not associated with a character until it plays. The name of the latter also supports the notion that Sans is fighting the player and not vice-versa.
 * According to an interview with Toby Fox, this was one of the six songs originally composed for other projects. The other five were "Fallen Down", "Heartache", "Nyeh Heh Heh!", "Bonetrousle", and "Another Medium".
 * Toby Fox has composed a 'sequel' to Megalovania dubbed "Megalo Strike Back" which was composed for the I Miss You - EarthBound 2012 album.
 * Toby Fox has stated that the version found in the fangame, "Cognitive Dissonance" or "CogDis", was not made by him.
 * This song may be the most popular among fans. An explanation might include its use in the aforementioned media combining the mainstream acclaim of Undertale.
 * The original version of Megalovania was in the key of A minor, whereas the version found in Undertale is a pitched up, slightly faster and modified version in the key of D minor.