The Orange Democratic Movement (ODM), Kenya's main opposition alliance, had called the march to the government registrar's office to complain that an ally of Daniel arap Moi, the former president, was made head of the Kenya African National Union (Kanu).
"Kenyans do not need a permit to visit a public office. This is the highest form of violence."
Last week, Nicholas Biwott, a powerful minister under Moi, was approved. Many Kenyans still view him with suspicion.
The government said the march would be illegal, and police used tear gas against the crowd. They beat some with truncheons outside parliament.
Nazlin Omar, of the ODM, said: "Kenyans do not need a permit to visit a public office. This is the highest form of violence."
Gideon Kibunjah, a police spokesman, said the demonstration had not been cleared in advance as required by law, and anyone involved was subject to arrest and prosecution.
Kenyatta's faction in Kanu, the country's oldest political party, wants the party to stay within the ODM, which Biwott and Moi oppose.
ODM complained the registrar's move was a government-backed plot to split Kanu and keep Kenyatta's wing from steering the party which Moi had once ruled when president.
Many Kenyans believe Moi still controls Kanu, and analysts say that is why Kenyatta failed to win the 2002 elections that brought Mwai Kibaki to the presidency. Kibaki initially served as Moi's finance minister and vice president.
Despite a series of corruption scandals implicating his government, opinion polls show Kibaki as the favourite to win next year's elections. A united ODM, however, could make it a tight race.