Some 370,000 people have fled recent clashes in Abidjan - many from Abobo, which backs Alassane Ouattara, Mr Gbagbo's presidential rival.
Gbagbo loyalists have been accused of atrocities against his rivals' backers.
Mr Ouattara is widely recognised as the winner of last year's elections.
A UN spokesman said a team that went to Abobo "could see that the armed forces of President Laurent Gbagbo fired at least six missiles on the market and surrounds".
Hamadane Toure said the shells killed 25 to 30 people and had injured between 40 and 60, AFP reports.
He said the UN expressed its "indignation in the face of such atrocities against innocent civilians" and vowed that the "perpetrators will not go unpunished".
'Piled-up bodies' One resident of Abobo told BBC Afrique the shells had come from a nearby barracks.
"We heard artillery fire - we ran to where the shells had landed, at Abobo roundabout - there's a small market opposite the town hall," he said.
Ivory Coast: Battle for power
- 410 killed since disputed election
- 450,000 forced from their homes
- 9,000 UN peacekeepers to monitor 2003 ceasefire
- Election intended to reunite country
- World's largest cocoa producer
- Previously seen as haven of peace and prosperity in West Africa
- Alassane Ouattara recognised as president-elect
- International sanctions imposed to force Laurent Gbagbo to go
They have set up roadblocks in Abobo and other pro-Ouattara districts of Abidjan, saying they are needed to protect residents from attack by Gbagbo loyalists.
The UN says that 410 people have been killed since the November election.
The African Union has given Mr Gbagbo until 24 March to organise a handover of power but he shows no signs of stepping down.
International sanctions have been imposed on Mr Gbagbo's allies in a bid to force him from power.
The election was supposed to reunify the country, which has been divided since a 2002-3 conflict.
Pro-Ouattara forces control the north of the country and many fear that a civil war could resume.
The New Forces rebels have mainly stayed on their side of the ceasefire line but they have seized some ground in the west.
Fighting here has led some 75,000 to flee into neighbouring Liberia.
Ivory Coast used to enjoy the highest living standards in West Africa and the world's biggest cocoa producer was seen as a haven of stability in the troubled region.