Since the beginning of the month access to media such as WhatsApp, Facebook and Twitter, as well as dating sites Tinder and Grindr, have been blocked unless users pay a 200 shilling ($0.05) daily tax.
In a statement, President Yoweri Museveni justified the move saying many citizens did not pay their taxes as they were meant to, and should not "donate money to foreign companies through chatting or even lying" on social media.
Wednesday's rally was led by singer and parliamentarian Bobi Wine whose election last year was fueled by social media.
Scores of protesters marched toward parliament, with the rally turning chaotic as a large group of market vendors and motorcycle taxi drivers faced off against police in anti-riot gear, with some lobbing stones at the officers.
"Tear gas was fired and some live ammunition was fired into the air to disperse the crowd," said police spokesman Luke Owoyesigire, adding two protesters had been arrested.
"During the unlawful procession officers had to act. Some of our officers were assaulted."
Police attempted to arrest Wine, but his supporters successfully defended him and he arrived at parliament where he hoped to address MPs later Wednesday.