Some rioters looted paintings from an art gallery and televisions from government offices. Others vandalised cars parked on downtown streets.
"From 11:30 pm [15:30 GMT] on Tuesday there will be a four-day state of emergency," an announcement from the president said.
According to national television, a curfew began at 10pm and anyone on the streets after that time without documentation would be arrested.
The crowds reportedly thinned after the president's declaration, which permitted police to use force in dealing with the protesters.
"Police will use necessary force to crack down on criminals who are looting private and government property," Munkhorgil, the minister of justice and home affairs, said.
Up to 30 police officers and 25 civilians have been injured and hospitalised, according to television reports citing local goverment and hospital officials.
"The demonstrators are acting like hooligans and violating social order," Sainbayar, a police spokesman, said.
The protest by an estimated 6,000 people in the capital Ulaan Baatofr began peacefully but by evening there was reportedly unrest in several areas of the city.
"The people have come here to fight for their freedom," one protester told the AFP news agency.
Journalist Irja Halasz told Al Jazeera that the rioters had prevented firefighters from reaching the burning MPRP building.
"The police have withdrawn their lines back because of the rioters throwing a lot of stones, and at this point it looks like no one is in control," she reported from the building next to the headquarters.
The Democratic Party, led by Tsakhia Elbegdorj, has accused the MPRP of stealing Sunday's vote.
|Up to 30 police officers and 25 civilians
were reportedly injured [EPA]
The MPRP, a former communist party, says that it won 45 seats in the 76-seat Great Khural, while the Democrats have reportedly won 21 seats.
The General Election Committee has yet to make a formal announcement on the ballot.
"We do not accept these results," Elbegdorj told a news conference earlier on Tuesday.
"No one needs these kinds of results, and they will be corrected in accordance with law."
Protesters at the election commission demanded that the body's officials resign over voting irregularities and fraud.
International observers say that overall the election was free and fair, but new election rules that changed the first-past-the-post system to one of multi-member constituencies have led to procedural problems and confusion.
'Free and fair'
Sanjagiin Bayar, the prime minister, called for calm in a televised address from inside the party headquarters before the fires were started.
"The other party [the Democrats] is accusing us of buying the election, it's not true, the election was free and fair. We now request that everyone should stop this chaotic protest immediately," Bayar said on local Eagle Television.
"Elbegdorj made a false announcement and he is misleading people and inciting violence."
The officially neutral Enkhbayar - previously an MPRP member - held an emergency national security meeting with Bayar and all the opposition party leaders.
At the meeting broadcast live on the privately-run Eagle television, Bayar renewed his calls for restraint while blaming the Democrats for inciting the rioters.