Gabor was born as Günszberg Dénes, into a Jewish family in Budapest, Hungary. In 1900, his family converted to Lutheranism. Dennis was the first-born son of Günszberg Bernát and Jakobovits Adél. Despite having a religious background, religion played a minor role in his later life and he considered himself agnostic. In 1902, the family received permission to change their surname from Günszberg to Gábor. He served with the Hungarian artillery in northern Italy during World War I.