The electricity box feeding the man's flat on the first floor of a building in the Kreuzberg area of the capital caught fire shortly after 1.30 am on Monday, and the resulting smoke set off alarms in the staircase, Klaus Schubert, a Berlin police spokesman told The Local.
Neighbours called the fire brigade who quickly discovered the cannabis plants and notified police.
"By the time officers arrived, he was standing by the front door waiting for them," Schubert said.
"He did not try to deny anything, but said that he was broke and had started growing the plants to make some money. There was a whole room full of them, with lighting, a watering system and heating, all wired up to the electricity system."
Schubert said that people growing cannabis in their homes often tried to do their own electrics to circumvent the meters, not only reducing their bills for the increased electricity usage, but also in order to prevent providers becoming suspicious about the amount of energy they use.
"The extra electricity consumption for such a system can certainly be noticed - it's as if one had a washing machine running the whole time," he said.
No arrests were made.