He graduated from high school in 1913 and entered the Law faculty of Franz Joseph University in Cluj (Kolozsvár), but was forced to interrupt his studies upon the war's outbreak.
Within a year of joining combat, he was made a second lieutenant in the Austro-Hungarian Army. He fought in Russia and Galicia, sustaining multiple injuries. However, once arrived on the Romanian Front, he decided that rather than fight against his fellow Romanians, he would join them.
Between his unnatural soldierly duty and his holy duty as a Romanian, Rebreanu heeded the latter."
Thus, on the night of May 10–11, 1917, having escaped from the infirmary where he was sequestered, he tried to cross the front to the Romanian side, bringing with him the plans for dividing and positioning Austro-Hungarian troops in the area. He was found and arrested by a patrol of imperial officers. Tried by a military court of the 16th Honvéd brigade, on May 12–13, on a charge of desertion and espionage, he was stripped of his rank and sentenced to death.
As an added humiliation, the method was specified as hanging. According to eyewitnesses, before being executed at 10 p.m. on May 14, he pushed aside the executioner and before the multitude of soldiers, many of whom were Romanians brought there as a warning, shouted powerfully, "Long live Greater Romania!"
When he found out about the hanging, he had already been thinking of a novel drawing upon Emil's letters from the front describing the atmosphere there. Subsequently, he incorporated what Emil had undergone into the book.
Among the individuals whom he fictionalized were successive love interests Elena Haliță ("Marta Domșa") and Ilona Lászlo ("Ilona Vidor", daughter of Făget's mayor in real life, but of a gravedigger in the book), as well as General Karg, who issued the death sentence. In October 1921, he was present at his brother's exhumation and reburial on the soil of the former Romanian Old Kingdom, which the latter had requested prior to being hanged. A street in Bistrița bears Emil's name since 1995, one in Năsăud since 1996, and there is one in Onești as well.
In 2012, a monument was unveiled in his memory at the border between Ghimeș-Făget and Palanca in Bacău County, around the place where the hanging is believed to have occurred. Four meters high and made of stone and bronze, one side depicts him in effigy, while the other shows Saint George.