A Toronto man says he woke up to "massive flames shooting out the sides" of his Samsung S5 phone on Tuesday morning.

Mario Jakab went to bed around midnight on Tuesday, and woke up from the heat and firework-like sounds coming from his bedside table.

Jakab says his Samsung Galaxy S5 caught fire on Tuesday night while charging and started shooting 'massive flames' out the side. (CBC)

"I jumped out of bed, alerted my girlfriend because I wasn't sure if anything was going to catch fire," said Jakab. "I waited for the fire to go out, because I'm not touching a flame."

In a statement to CBC Toronto, a spokesperson for Samsung said customer safety was their highest priority.

"Upon being made aware of the reported incident we began working with Mr. Jakab to investigate the matter. Until we have had an opportunity to analyze the phone we are unable to comment on the matter further."

- Mario Jakab

Samsung has recalled batteries on the Galaxy Note 7 models, after the devices started catching fire. The S5 model is not included in the recall. This appears to be one of the first reports of an S5 catching fire, though a lawsuit filed in the U.S. alleges the problem extends to several other smartphones.

Jakab said a Samsung engineer picked up his device on Wednesday morning. When asked if he had modified the phone, he told them the battery and charging cable were all originals that came with the phone he bought in 2014.

Jakab plugged his phone in to charge around midnight, and woke up around 4 a.m. after hearing crackling noises, like fireworks coming from his bedside table. (CBC)

"I couldn't pick up my phone or take a video of what it was doing, or even call 911," he says.

Jakab doesn't want to think what might have happened if he didn't wake up, or if the phone was in his pocket.

He wants people to learn from what happened to him and protect themselves, but said he would likely not change his own habits when it comes to charging his phone at night.

Jakab says the battery and charging cable are all originals, and that he has not modified his phone since purchasing it in 2014. (CBC)

He also worries about children playing with Samsung phones.

"Just a battery heating up can burn a young child's hands, just from holding it," he said. "Apparently they're not toys, like we thought they were."