Canadian online-store provider Shopify is prohibiting the sale of many types of guns and ammunition, saying that "solely deferring to the law" no longer works amid political gridlock and the internet's rapid pace.

In an update of its rules earlier this week, the Ottawa-based e-commerce giant, which services more than 600,000 small businesses, banned merchants from using its technology to sell weapons including semi-automatic firearms, silencers, grenades, rocket launchers and 3D-printed guns.

"From time to time, Shopify reviews and amends the terms, conditions and policies governing the use of our platform. We have recently amended our Acceptable Use Policy (AUP) to restrict the sale of certain firearms and parts on our platform," the company stated in an email. "As we continue to scale globally, we may further refine our policies as needed."

Get Breaking News Delivered to Your Inbox

The company told the Associated Press that the change affected "a small number of merchants," but would not give a specific number.

The decision to enter the fray over guns—a particularly heated debate in the U.S.—marks a change in stance for Shopify, which in the past has shown a reluctance to get drawn into cross-border debates.

"Solely deferring to the law, in this age of political gridlock is too idealistic and functionally unworkable on the fast-moving internet," Shopify CEO Tobi Lutke wrote in a blog post. "We addressed this vacuum by creating a carefully crafted acceptable use policy which allows space for all types of products, even the ones that we disagree with, but not for the kind of products intended to harm."

Last year, Shopify refused requests from activists to stop providing technology that allowed conservative news site Breitbart to operate its online store. Lutke explained at the time that commerce was part of free speech.

"If we start blocking out voices, we would fall short of our gals as a company to make commerce better for everyone," he wrote. "Instead, we would have a biased and diminished platform."

The company, which derived 71 percent of its $673 million in revenue last year in the U.S., had already banned the sale of products that explicitly endorsed violence against others based on their ethnicity, religion or gender.

Earlier this year, big retailers including Walmart, Kroger and Dick's Sporting Goods changed their gun policies after a high school shooting in Parkland, Florida, in which 17 people were killed.