Thousands of angry protesters stormed Burkina Faso's parliament and ransacked state television, forcing it off the air ahead of a planned vote on a motion to allow the veteran president to extend his 27-year rule.

Black smoke swirled in the air around parliament in Ouagadougou after demonstrators lit fires inside the building.

Security forces protecting the area near the presidential palace fired live rounds and tear gas as crowds approached.

Police protecting the house of President Blaise Compaore's brother opened fire as demonstrators tried to attack the building, leaving three bodies lying motionless on the ground, a witness said.

Parliament had been due to vote on a plan to change the constitution to allow President Blaise Compaore -- who took power in a coup in 1987 -- to stand for re-election again next year, when he was due to stand down.

Compaore's attempt to remain in power has deeply divided Burkina Faso, one of the world's poorest nations.

Compaore has ruled the cotton and gold-producing nation with a firm grip but, in recent years, he has faced increasing criticism, including from within his own camp and the military.

Burkina Faso Blaise
President of Burkina Faso, Blaise Compaore, is pictured in New York in September 2013 (Reuters)

Opposition to Compaore's plan have been mounting in recent days. Hundreds of thousands of people took to the streets of Ouagadougou and other towns across the country on Tuesday in what the opposition said was the start of a campaign of civil disobedience over the proposed constitutional reform.

burkina faso
Police fire tear gas at protesters in Ouagadougou, after tens of thousands of people marched through the capital of Burkina Faso, calling for President Blaise Compaore to abandon plans to hold a referendum on changing term limits to allow him to stay in power (Reuters)

The protests have led to the government abandoning plans for legislation to extend President Blaise Compaore's 27-year rule.

Alain Edouard Traore, communications minister, confirmed the government had dropped a plan to amend the constitution to remove a two-term presidential term limit that would have allowed Compaore to seek re-election next year.