The incidents described in the stories are modeled on Maugham's experiences as a secret agent, and "the central character, Ashenden, is very much an autobiographical character." He is supposed to have modeled Chandra Lal after Virendranath Chattopadhyaya, an Indian nationalist in Germany during the war. Maugham, who was in the British Secret Service in Europe during the war, based many of his stories on his own experiences. Among other enterprises, Britain's European intelligence network attempted to eliminate several Indian nationalists in Europe, notably members of the Berlin Committee. Donald Gullick, a British agent, was dispatched to assassinate Chattopadhyaya. At the same time, the latter was on his way to Geneva to meet another Indian nationalist, Mahendra Pratap, and forward the Kaiser's invitation to Berlin. The short story of Giulia Lazzari is a blend of Gullick's attempts to assassinate Chattopadhyaya and Mata Hari's story. Winston Churchill reportedly advised Maugham to burn 14 other stories.
The 1936 Alfred Hitchcock-directed film Secret Agent is a loose adaptation of "The Traitor" and "The Hairless Mexican," with John Gielgud as Ashenden (whose "real" name is Edgar Brodie) and Peter Lorre as The General.