The Ontario government has inked a deal to use Shopify Inc.'s e-commerce platform for cannabis sales online and in stores as part of its plan to be the province's sole distributor of legal recreational marijuana.

The Ontario Cannabis Retail Corporation (OCRC), a subsidiary of the Liquor Control Board of Ontario, will use the Ottawa-based company's online store software for its online and mobile sales portal.

"Our top priority is fulfilling the province's framework for the safe and sensible retailing of recreational cannabis for when it is legalized by the federal government," said George Soleas, president and CEO of the LCBO.

"We look forward to combining our expertise as a socially responsible retailer with Shopify's world-class commerce solutions to deliver the safe, informed and reliable shopping experience that our new customers will expect."

Shopify's technology will also be used inside brick-and-mortar stores to process transactions on iPads and for digital screens displaying product and health information.

The OCRC said Ontarians will have access to the same product information, usage guidelines and social responsibility information -- which adhere to federal marketing provisions -- both in-store and online.

The public consultation for Health Canada's proposed guidelines for cannabis regulation -- which include limits on branding elements on packaging, as well as restrictions on marketing similar to tobacco -- finished on Jan. 20, with a finalized version yet to be delivered.

The agency selected the tech darling to provide point-of-sale systems for in-store and online sales in late 2017.

"Bringing this differentiator to the LCBO on this historic project to consumers of legal age across Ontario, is a great example of a made-in-Canada innovation, which we are proud to be a part of," said Loren Padelford, vice-president of Shopify Plus, the division that focuses on big clients.

Shares of Shopify in Toronto rose more than 7 per cent to close at $161.05 on Monday.

The OCRC is in the process of determining the design for the user experience, with the aim of having operations installed in time for the proposed federal marijuana legalization launch in July 2018, the agency said.

In addition to online sales, Ontario will roll out an initial wave of 40 stores which are expected to grow in number to 150 by the end of 2020

The government agency will also use Shopify's platform to manage inventory, accounting and human resources operations.

Sales of the drug in Ontario will only be available through government-run online or in standalone stores, while some other provinces such as Alberta and British Columbia are allowing for some private sales of cannabis.