Otto was born as Prince Otto Friedrich Ludwig of Bavaria at Schloss Mirabell in Salzburg (when it briefly belonged to the Kingdom of Bavaria), as the second son of Crown Prince Ludwig of Bavaria and Therese of Saxe-Hildburghausen. His father served there as the Bavarian governor-general. Through his ancestor, the Bavarian Duke John II, Otto was a descendant of the Byzantine imperial dynasties of Komnenos and Laskaris. His father was a prominent Philhellene, and provided significant financial aid to the Greek cause during the War of Independence.