Morris, 39, had served three years in the Dade Correctional Institution after being sentenced to 20 years following his 1982 conviction on four drug-related charges.
He was awaiting a new trial, which the state Supreme Court granted in March, when he entered the no-contest plea to one count of conspiracy to traffic in cocaine. As part of the plea bargain, prosecutors dropped three other charges.
"I would not give in," a jubilant Morris said following the 10-minute hearing.
Flanked by his wife, Bobbie, and 4-year-old daughter, Tiffany, Morris, who was furloughed from prison after the Supreme Court ruling, told reporters, "I believed the consistency of the truth would win out."
Dade Circuit Judge Ellen Morphonios sentenced Morris to 4 1/2 years on the conspiracy charge, giving him credit for the time he served before the new trial was ordered. She also awarded him 1 1/2 years credit for good behavior since he entered prison in 1983, thereby setting him free.
Before Morris left the courtroom, the judge also praised his recent television work to educate the public against the risks of drug use.
"I've seen the TV ads and they're great," she said. "You've done a whole lot of good. You really have."
By entering a no-contest plea, Morris neither admitted guilt nor claimed innocence but only agreed not to challenge the state's case, said his attorney, Phil Glatzer.
Morris, who pleaded innocent in his first trial, had argued that he was entrapped by police and Fred Donaldson, a friend who said he was angry that Morris did not pay him for gardening work he performed.
The state's high court ruled 5-1 that Morris was unfairly prohibited from presenting testimony by Eugene Gotbaum, who said in an affidavit that he heard Donaldson say he planned to set up Morris in some type of drug deal. The trial court called the testimony hearsay.
Morris, who helped the Dolphins become the only unbeaten team in modern National Football League history with a 17-0 season in 1972, now gives anti-drug speeches at churches, schools and conventions.
"Being a professional athlete for 20 years has given me the opportunity to see you have to have a victory over these things," Morris said.
Morris said he would finish a book on his life and travel the country lecturing NFL players against drug abuse.
"You're not going to see the end of this problem in drugs until you stop idolizing the drugs," he said.