Military judge Lt. Col. David Jones had recommended Tuesday that he spend three months in the brig, but he said his hands were tied by the plea agreement.
Staff Sgt. Frank Wuterich pleaded guilty to negligent dereliction of duty as part of a deal with prosecutors.
Wuterich led the Marine squad in 2005 that killed 24 Iraqis in Haditha after a roadside bomb exploded near a Marine convoy, killing one Marine and wounding two others.
Wuterich was originally charged with nine counts of manslaughter, but those charges were dropped, and the minor charge of negligent dereliction of duty carried a maximum sentence of 90 days.
However, with the way the military system works, the terms of the plea deal weren't known to the judge until after he made his sentencing recommendation in court on Tuesday.
Wuterich has acknowledged ordering his squad to "shoot first, ask questions later" after a roadside bomb took the life of a fellow Marine, but he said he did not shoot any of the 10 women and children killed in nearby homes that he stormed with his men.
"The truth is: I never fired my weapon at any women or children that day," Wuterich told Jones.
Wuterich's statement countered testimony from a former squad mate who said he joined Wuterich in firing in a dark back bedroom where a woman and children were killed.
The plea deal, which ends the largest and longest-running criminal case against U.S. troops to emerge from the Iraq War, has sparked outrage in Iraq. Six other squad members have had charges dropped or dismissed. One man was acquitted.
In a statement, Wuterich addressed family members of the Iraqi victims, saying there were no words to ease their pain.
"I wish to assure you that on that day, it was never my intention to harm you or your families. I know that you are the real victims of Nov. 19, 2005," he said.
The Associated Press contributed to this report.