Delivering her sentence, Judge Thokozile Masipa cited the "gross negligence" the double-amputee Olympic runner showed when he shot Steenkamp multiple times through a toilet cubicle door in his home.
Pistorius, who cried and retched during his murder trial, was unemotional as he stood to hear his sentence. His prison term begins immediately and he was led by police down a flight of stairs to holding cells before leaving the courthouse in the armored vehicle.
The world-famous runner later arrived at the nearby Kgosi Mampuru II prison in the South African capital, a facility that has had problems with violence and overcrowding and where during the years of apartheid death row inmates were executed before capital punishment was outlawed with the advent of democracy. Despite the prison's reported problems, authorities have said Pistorius would be held away from the general prison population because of his disability and high profile -- possibly in a hospital wing or a high-security section.
Pistorius could be released after 10 months to serve the remainder under house arrest, according to legal experts. Masipa last month convicted Pistorius of culpable homicide, or negligent killing, but acquitted him of murder after he testified he mistook Steenkamp for a nighttime intruder.
Steenkamp's parents were in court to hear the sentence and the dead model's mother, June, said justice had been done. A close friend of Steenkamp, Gina Myers, said: "I really don't think any of us will heal anytime soon ... there will always be questions."
Pistorius' uncle, Arnold Pistorius, appealed to reporters to give the family privacy after what he called "20 months of relentless public trial." He criticized prosecutors for pursuing a premeditated murder charge against Pistorius, and said "they decided to inflict as much collateral damage as they could." He said Pistorius' family accepted the sentence.
"Oscar will embrace this opportunity to pay back to society," Arnold Pistorius said.
Judge Masipa earlier described the sentencing as a balancing act between retribution and clemency.
"I am of the view that a non-custodial sentence would send a wrong message to the community," Masipa said, taking just over an hour to summarize parts of the case and explain why she reached her decision. "On the other hand, a long sentence would not be appropriate either as it would lack the element of mercy."
Masipa asked Pistorius to stand as she delivered the sentence, and he faced her with his hands clasped in front of him. Pistorius was then led away, stopping briefly to grip the hands of his uncle and other family members as he headed to prison.
Prosecutors said they are considering whether to appeal the sentence, where Pistorius, 27, could serve less than a year in jail for killing his 29-year-old girlfriend. They have 14 days to apply for permission to appeal.
Nathi Mncube, the prosecution spokesman, said his office was disappointed in the culpable homicide conviction and had not yet decided whether to appeal. He said that there was an "appetite" to appeal but prosecutors would review their options.
"We are satisfied with the fact that he will be serving some time in prison," Mncube said.
Masipa had a wide range of options available to her because South Africa does not have a minimum sentence for culpable homicide, which is comparable to manslaughter. Pistorius, a once-inspiring athlete, known as the Blade Runner because he competed on carbon-fiber blades, was the first amputee to run at the Olympics in 2012. He had faced up to 15 years in jail. He also could have received a completely suspended sentence or house arrest.
The sentence raised questions over if Pistorius, a multiple Paralympic champion, would ever return to the career that made him famous. The International Paralympic Committee said he would not be eligible to run during his five-year sentence, ruling him out of the 2016 Rio de Janeiro Paralympics.
Pistorius must serve one-sixth of his sentence in prison -- 10 months -- before he is eligible to be moved to house arrest, said Marius du Toit, a legal analyst and criminal defense lawyer.
"It's an appropriate sentence," du Toit said.
As Pistorius left in the police van, a crowd gathered around the vehicle, with some whistling, shouting and banging on the caged windows.
Muted Reaction As Pistorius Sentenced To Prison
ABC News' Alex Marquardt reports from South Africa, where Oscar Pistorius was sentenced to five years in prison.