"In D&D, there is no act more reckless and fraught with danger than that of outsmarting the DM."
— Shamus Young
Most Tabletop RPGs isolate one player from the rest to fill the role of the Game Master (or GM), comprising four major "hats" to wear:
Author: The GM plans out (in the loosest sense) the plot of the story of which the Player Characters will become heroes (or villains, or rich, or whatever); creating (or adapting, or just choosing) the setting, populating that region with villains and other NPCs, and assigning them any necessary backgrounds, motivations, plans and resources. Beware, as overdoing this aspect can lead to Railroading.
Director: During the game, while each of the other players typically controls the actions of one of the Player Characters, the GM decides the actions of all the NPCs as they are needed. The GM may also direct a particular "NPC" that travels with the party (commonly known as a GMPC), but this may occasionally be open to abuse since the Game Master having a "pet" NPC may compromise his neutrality.
Referee: In most Tabletop RPGs, the rules are supplied to resolve conflicting situations (avoiding the "Bang! you're dead!"/"No, you missed!" quandary). The GM is expected to provide any necessary interpretation of those rules in fuzzier situations. The GM may also approve or provide House Rules in order to cover these corner cases or provide a different gaming experience. See also Rule Zero.
Manager: The least officially prescribed portion of GMing, and thus the part that takes people the most by surprise. The GM is typically the one to organize the game in the first place, find players, schedule sessions, and figure out a place to play, as well as acting as a mediator and having to balance the needs and desires of all participants — sometimes having to divine the real desires of indecisive or self-deluded players.
Often, the GM is separated from the other players at the table by a cardboard screen that hides his notes on NPCs and upcoming events in the story; many games print custom GM screens, decorated with various tables and charts from the rulebooks, to reduce the amount of book referencing needed during play. Such screens have become less common — most GMs and players prefer to use their computer to create their own screen, if they ever use one at all.
Game Masters will often be practiced actors, and many of the better GMs are also talented vocal artists and authors — for some, they're skills that see a lot of use, and many games have come into legend because of a memorable GM-controlled NPC.
The Game Master may encourage a variety of game styles (ranging from dice-heavy hack-and-slash to semi-freeform roleplaying) and moods (ranging from the sadistic and adversarial to loot raining from the heavens).
Not to be confused with General Motors. Unless you're running some sort of automobile centered RPG. Note that the GMs in MMO Games (RPG or otherwise) are more like moderators with punitive powers but no ability to change the fundamentals of the game itself. They're the cops, in other words, whereas a Tabletop GM is the ruling deity of his or her world.
Renaming the Game Master is a popular option to add a dash of custom flavor to a game:
"Referee" was the original term, as used in the very first version of Dungeons & Dragons (published in 1974 by Gary Gygax and Dave Arneson, may they Role-play In Peace), and in Traveller (published in 1977).
"Dungeon Master", or "DM", in Dungeons & Dragons; this term arrived with Advanced Dungeons & Dragons, with Game Master being a genericized expansion from it.
"Star Master", or "SM", in Space Opera by Fantasy Games Unlimited.
"Hollyhock God" in Nobilis (yes, it's a weird game).
"High Programmer" in Paranoia...sort of. Actually the text usually calls him the Game Master, but the GM's section is labeled "Ultraviolet" clearance - which is the clearance of High Programmers.
Lampshaded in the 25th Edition corebook on High Programmers: Unlike all other books, there is no GM section, since the High Programmers are the PCs, here. Instead, the GM notes get sprinkled around, with the PCs being told to please not metagame, thank you.
The Board Games Hero Quest and Descent both cast the Dungeon Master as the Heroes' actual antagonist, the former as the Big Bad (Zargon or Morcar, depending on where you bought the game) and the latter as the Monster of the Week, called the Overlord.
However, Descent's Road to Legend supplement has the Overlord act much more like a traditional Evil Overlord, with evil minions and a plot beyond "kill the other players".
"Host" in Ironclaw, Jadeclaw, and other games from Sanguine Productions — a term that deliberately emphasizes the Managerial hat in addition to the others. Even if the "Host" isn't inviting the other players into his home, he's inviting them into his world.
The '70s third-party supplement vendor, Judges Guild, got its name from the assumption that the DM was the game's "Judge," but it never caught on as a generic term.
Yet they still insist on calling the DM that even today, in a rather Anvilicious manner. They really don't ever give up, do they?
Though TSR themselves used it as a term for the GM of their Marvel Super Heroes role-playing game.
"Director" in the RPG adaptations of Buffy, Angel, and Army Of Darkness.
In Castles and Crusades, they use the term "Castle Keeper."
The 1980's company "Pacesetter" (currently out of business) always came up with a term that would fit the initials CM. For their horror game Chill, it was "Chill Master", Star Ace games were run by a "Campaign Master", and Timemaster had the "Continuum Master".
"Dispatcher" in the Ninja Burger RPG (second edition). Though, in this game, the GM takes on a more proactive role in the game and is an actual party member for all intents and purposes.
DragonRaid uses the generic-sounding (but not actually very common) "Adventure Master."
The Red Dwarf Roleplaying Game calls them the "AI", and encourages a bit of acting on their part beyond the norm.
Call of Cthulhu and all related games use "Keeper of Arcane Lore," usually abbreviated to just "Keeper".
The CRPG themed "Console" and "Super Console" calls him the "CPU".
"Game Master" in Rifts and other Palladium systems.
"Gamesmaster" in Warhammer Fantasy Roleplay. Also in Warhammer Quest (the optional roleplaying rules).
"Host" in Castle Falkenstein, to maintain the 19th century drawing-room atmopsphere. Similarly, a PC is a "Dramatic Persona".
"Overseeer" in Fallout Pen and Paper.
As Model United Nations has been described as LAR Ping in suits, and crisis committees—in which you have constantly-changing topics of discussion—require direction, the equivalent position to Game Master is the "Crisis Staff" (a collective GM of 3-5 members, typically) and the players are "Delegates".