Police raided the home of Dionis Cerriku in Streetfield Crescent, Rossington on June 9 this year when they found hundreds of cannabis plants, Sheffield Crown Court was told.
Prosecuting, Neil Coxon, told the court that officers found plants of varying levels of maturity, located in three of the property's bedrooms as well as the kitchen.
He said: "From the kitchen they recovered 160 plants that measured between 11 and 12cms in length.
"Police also recovered 32 plants from a bedroom that were more mature and were 101-103cms.
Rivelin Valley Road Sheffield: Body found after police search of Rivelin Valley
Hosepipe ban: Reservoir near Sheffield less than 15 per cent full as photos show how water levels have plunged
Sheffield weather: Met Office issues thunderstorm warning as heatwave set to end with heavy rain and lightning
Rotherham missing boy: 13-year-old missing for 10 days as police make appeal
The Long Blondes: Leadmill cancel gig after allegations surface against band creator Dorian Cox
"In the second bedroom they found a further 39 plants that were measured as being between 88 and 89cms.
"22 plants were recovered in the third bedroom that were the most mature of them all, they were between 111 and 125cms."
In total, officers recovered some 252 plants from the property and 10kg of the Class B drug.
The court was told that should the plants have been allowed to mature, they had the potential to yield hundreds of thousands of pounds worth of cannabis.
Cerriku was arrested, and exercised his right to make no comment in police interview.
He later pleaded guilty to the production of cannabis.
During today's sentencing Recorder Ray Singh gave Cerriku another chance to explain the reason he was growing cannabis in such vast quantities.
Appearing via video link from HMP Doncaster, he said: "It was a job for me."
Recorder Singh sentenced him to two years in prison.
He said: "There was in excess of 250 plants.
"There were being grown across the property.
"If these plants had been capable of being harvested that 10kg would have been sold for a significant amount, with a value stretching into hundreds of thousands of pounds."
He added that he regarded Cerriku to play a significant role in the production of the drugs.
Recorder Singh also made an order for the destruction and forfeiture of all of the plants seized.