A massive landslide has torn through a ravine in northwest Colombia, killing 56 people and injuring scores more, authorities have said.

Most residents were sleeping when the landslide hit the municipality of Salgar around 3am on Monday, burying a large area in mud and debris.

The rush of mud and water "tore down everything in its path," Salgar Mayor Olga Osorio told RCN Radio.

The small town of Santa Margarita was practically "wiped off the map," she said.

Aerial images showed a broad river of mud that had inundated a large area, dragging houses and trees along with it.

Residents shovelled out piles of mud on Monday afternoon, trying to salvage what belongings they could, as dump trucks arrived to begin hauling away the mess.

President Juan Manuel Santos flew over the affected area and met with local officials, the AFP news agency reported.

"No one can bring the deceased back to you, that is something we deeply regret. But we have to get through this disaster and look to the future with bravery and strength," he said.

"Several" children were orphaned and are being cared for by the Colombian Institute for Family Wellbeing, Santos said.

He announced that each family affected, 30 in all, would receive $7,000, and promised infrastructure improvements to try to prevent such disasters in the future.

Former president turned opposition leader Alvaro Uribe also visited the area, which is near where he grew up.

"I met a woman who was holding her three-day-old grandson. His parents are lost," he told RCN. "It's very painful what we saw."

Heavy rain

Santa Margarita, the hardest-hit town, is one of four that make up Salgar, a municipality of 17,000 people in the department of Antioquia.

It was cut off from the rest of the municipality because of damage to an access road and a bridge, local media said.

The area was left without electricity, drinking water or gas, and 31 homes were damaged, officials said.

Extra emergency teams, rescue dogs and humanitarian aid have been sent, said Red Cross spokeswoman Ana Carolina Gutierrez.

The area had been hit by several days of heavy rain.

Colombia's tropical climate and mountainous landscapes make it prone to landslides.

In 2010-2011, heavy rains caused flooding and landslides that killed 1,374 people and destroyed more than 100,000 homes.