A court ruling has cast doubt on police powers to randomly pull over motorists.

Two African men were stopped by police in Ascot Vale last year.

One man was charged with assault when the situation escalated

A magistrate has now ruled the Road Safety Act does not give police the unfettered power to stop motorists without suspicion.

Magistrate Duncan Reynolds ruled "there is no common law power vested in police giving them the unfettered right to stop or detain a person and seek identification details.

"Nor, is s.59 of the (Road Safety) Act a statutory source of such power."

The lawyer representing one of the men, who is fighting assault allegations, Tamar Hopkins, says the decision will have ramifications.

"At present, we understand they're (police) told to go out and stop as many cars as they can," she said.

"This ruling says you can't do that. You must stop cars when there is in fact a reason.

"Random stops are in fact not lawful."

She says it is an important ruling.

"One of the problems with arbitrary stops is that they can be used by police to stop people on the basis of discriminatory grounds rather than after they have formed a reasonable basis to believe that the driver may have committed an offence," she said.

"Many people from African backgrounds, for example, have reported that they have been subject to routine intercepts by police where there is no underlying basis for the stop."

Stops for the purpose of random breath testing are not impacted by the court ruling.

"There is a specific statutory power for police to conduct stops for this purpose," Ms Hopkins said.

Victoria Police are considering their options, including whether to appeal against the ruling at the Supreme Court.