Sarah Ellahi, 27, abused her position as a family liaison worker at Armley Jail in Leeds in order to have the affair with the prisoner.
Leeds Crown Court heard the inmate’s cell was searched when staff became suspicious and they found printed pictures of Ellahi “in various states of undress.”
Gerald Hendron, prosecuting, said letters written by Ellahi were also found which were erotic and sexual in nature.
Some of the letters were signed “your wifey”, spoke of her love for the prisoner and discussed plans for when he was released.
A mobile phone found in the cell also revealed texts to and from Ellahi’s phone.
Mr Hendron said the phone had received 598 text messages from Ellahi and she had received 374 messages over a two-month period.
The court heard Ellahi and the inmate also discussed carrying contraband goods into the prison.
One message from Ellahi stated: “I want you to be able to ask me for stuff. I am your partner.”
Ellahi initially raised suspicion when she began volunteering to cover shifts for colleagues at the jail’s visitor centre. She even offered to work for free at times when the inmate was there.
In January this year, police seized her handbag and it was found to contain love letters she had written to the inmate.
She admitted writing and sending texts to the prisoner and giving him a wind chime as a present.
Ellahi, of Temple Crescent, Beeston, denied that any physical contact ever took place between them.
Ellahi pleaded guilty to misconduct in a public office and conveying a list C article into prison. She was given a four-month sentence.
The prisoner pleaded guilty to passing a prohibited item inside a prison and conveying a list C article into prison.
The court heard the inmate is currently serving a prison sentence for burglary offences and is awaiting trial on other matters. He was given a six month sentence.
Jayne Cooper, for Ellahi, said her client had been a family liaison officer at the prison for two years before her arrest.
Miss Cooper said Ellahi had a masters degree and was well regarded by her employer.
The court heard she had helped to put in place projects to enable inmates to spend more time with their children at the visitor centre.
Miss Cooper said Ellahi developed the relationship with the prisoner at a time when she was vulnerable and he had been kind to her.
Jailing Ellahi, judge Tom Bayliss, QC, said: “You became infatuated with him - besotted with him.
“You are an upstanding member of society and I accept that any prison sentence will impact hard upon you but the offence of misconduct in a public office is serious.
“Behaviour such as yours has the potential to compromise security within the prison and exposes you to the threat of blackmail.
“Inevitably it damages confidence in the prison system.”
Have you downloaded the free YEP app available on Android and iphone?