After 1903, when relations between Britain and Germany cooled, William Melville lobbied the government to create a counter-espionage service. In 1906 Melville obtained German mobilization plans and investigated their financial support to the Boers. He hired a Courage Brewery representative in Hamburg to supply intelligence for him and in 1909 went to Germany himself to recruit more agents. Melville's request was granted in October 1909 when the War Office authorized the creation of the Secret Service Bureau, nineteen military intelligence departments - MI1 to MI19, but MI5 and MI6 came to be the most recognized as they are the only ones to have remained active to this day.
His own section continued as a separate Special Section and he concentrated on looking for German spies. In August 1914 he eventually was able to identify the barbershop of Karl Gustav Ernst, that was the centre of a German spy ring. After the outbreak of World War I, Secret Service received more funding. Melville recruited more personnel for his section when it was attached to newly found G-section, that concentrated on investigating suspected agents. He also founded a spy school opposite the War Office at Whitehall Court.