The Guildmaster is the head of the Thieves Guild. The title for the Cyrodiilic Thieves Guild was the Gray Fox.
The Nerevarine becomes Master Thief of the Thieves Guild after killing Sjoring Hard-Heart. Gentleman Jim Stacey was the previous guildmaster of the Morrowind branch.
To become the Gray Fox, the Hero must have fenced the maximum, acquired all fences, and have completed the questline.
In order to achieve this rank in The Elder Scrolls V: Skyrim, the Dragonborn must restore the Guild to its former glory. This is completed by doing the special tasks given by Delvin Mallory. This may only be done after completing the questline. Mercer Frey was the previous guildmaster of the Skyrim branch.