Born in Craiova, his parents were Colonel Romulus G. Magheru, the son of General Gheorghe Magheru; and his wife Ana, the daughter of Ion Ghica. After his father's death when he was four, he was raised at the Ghica family's estate in Ghergani, where he received a rich musical and literary education. Alexandrina Ghica, his grandmother, was an accomplished pianist who had studied with Franz Liszt and Clara Schumann; his mother had studied fine arts in London. He attended Saint George primary school in Bucharest, followed by Gheorghe Lazăr High School, from which he graduated in 1911. The same year, he entered the medical faculty of Bucharest University, from which he would graduate in 1920. Meanwhile, Romania's entry into World War I found him a sixth-year student, and Magheru left for the front as a second lieutenant combat medic. He contracted a recurring fever and epidemic typhus, but refused to take leave and remained in the war-torn Moldavia region until demobilization. After obtaining his degree, he began to conduct research at the Cantacuzino Institute, where he would spend his entire career. Together with his wife Alice, a microbiologist, he wrote numerous specialized texts.
Although he began writing poetry at age fourteen, Magheru's published debut took place much later. He devoted himself to writing after 1923, when an illness forced him to Sinaia for a time. His first book was the play Tudor Ardeleanu (1926), followed by O legendă (1927); together, they formed the cycle Latinii la Dunăre. His first poetry book was the 1929 Capricii; according to Adrian Maniu, it contained "interesting and anti-poetic texts". As a result, Magheru polemically titled his next collection Poezii antipoetice ("Anti-poetic Poems"; 1933). There followed Poeme în limba păsărească (1936), Coarde vechi și noi (1936), Poeme balcanice (1936), and the plays Piele de cerb (1937), Domnul Decan (1939), Egoistul (a dramatization of George Meredith's The Egoist, 1939), Oglinda fermecată sau Divina re-creațiune (1944). Magheru never sought for his plays to be staged, even though they are hardly lacking in well-crafted scenes, a modern dramaturgical vision and debates about moral and philosophical issues. He lived a withdrawn existence and did not participate in the literary life of the interwar period. Isolated between his laboratory and a circle of friends drawn from the contemporary artistic elite (including George Enescu, Jean Alexandru Steriadi, Theodor Pallady, Henri Catargi, Dumitru Ghiață and Iosif Iser), he continued to write after 1944, but stopped publishing. Much of his late work has yet to be studied and published. In 1982, Marin Sorescu published part of his manuscript poems as Cântece la marginea nopții.