M is a fictional character in Ian Fleming's James Bond series; the character is the Head of Secret Intelligence Service—also known as MI6. Author Ian Fleming based the character M on a number of people he knew who commanded sections of British intelligence. Primary amongst these was Rear Admiral John Godfrey, who was Fleming's superior at the Naval Intelligence Division.
M has appeared in the novels by Fleming and seven continuation authors, as well as appearing in twenty-four films. In the EON Productions series of films, M has been portrayed by four actors: Bernard Lee, Robert Brown, Judi Dench and Ralph Fiennes, who is the current incumbent; in the two unofficial productions, M has been played by John Huston and Edward Fox.