Nathan Allen, 21, assaulted the three-week-old girl while she was in his care at a house in Aberdeen.
The infant suffered a brain haemorrhage after she was shaken and struck on the body on November 22 last year.
However, Allen denied harming the child and claimed she had been injured as a result of an accident.
He insisted he had been preparing to put the baby to sleep when she rolled off his arm and fell to the floor.
But the jury at his trial did not believe him and convicted him of endangering the child's life by assaulting her.
Allen was sentenced at Aberdeen Sheriff Court yesterday.
Sheriff Annella Cowan said: "In one view, that makes you an extremely dangerous person. The psychological assessment seems to hold, albeit limited hope, that you may be assisted to realise that you are not the centre of the universe."