Who owns code a contractor writes?
Written by For Founders Law, a Toronto firm licensed by the Law Society of Ontario. About us
Short answer
Under Canada's Copyright Act, the contractor does, unless they sign a written assignment to your company. Paying the invoice doesn't transfer ownership. Employees are different: the employer is the first owner of work made in the course of employment, unless they agree otherwise. Moral rights stay with the individual either way, unless they waive them.
The default rule
Canada’s Copyright Act treats a computer program as a literary work (section 2), so your codebase follows the same ownership rules as a book or an article. The starting point is that the author is the first owner of the copyright.
There is one main exception. Under section 13(3), when an employee makes a work in the course of their employment, the employer is the first owner, unless the two agree otherwise. That exception doesn’t reach contractors. A freelance developer, a dev shop, a no-code agency or a part-time CTO who bills through their own corporation isn’t your employee for this purpose, so by default they own what they build for you.
Paying in full doesn’t change that. Section 13(4) says an assignment of copyright is only valid if it’s in writing and signed by the owner. If you can’t point to a signed IP assignment, you may not own the code.
Code a founder wrote before incorporating
The same rule catches founders. Code, designs, prototypes and decks created before the corporation existed belong to whoever made them, and the company can’t own anything until it’s assigned in writing. Founders often build for months before they incorporate, so this is one of the most common gaps.
The fix is a founder IP assignment that expressly covers prior work, signed at or soon after incorporation. It’s often signed alongside the shareholder agreement so equity and IP move into the company together.
Moral rights
Moral rights protect the integrity of a work and the author’s right to be associated with it, or to stay anonymous. Under section 14.1, they can’t be assigned, only waived in whole or in part, and an assignment of copyright doesn’t waive them on its own. Under section 14.2, they last as long as the copyright.
A SaaS or AI company refactors, rebrands and modifies its product constantly, so an unwaived moral right is an unnecessary loose end. Put a waiver in every employment agreement, contractor agreement and founder assignment, drafted so it also benefits your licensees and successors.
AI models, weights and training data
AI startups have more kinds of assets than a typical software company, and each raises a slightly different question:
- Training and fine-tuning code is software, so the employee and contractor rules above apply.
- Datasets you compiled can attract copyright as a compilation, but the underlying records may belong to someone else or contain personal information.
- Licensed or scraped data is only as good as the licence or terms you got it under.
- Model weights and prompts aren’t clearly addressed by the statute, so contracts and confidentiality do most of the protecting.
- AI-generated output is unsettled. The federal government consulted on copyright and generative AI, with submissions closing in January 2024, and hasn’t changed the law. Don’t assume output is automatically yours, or automatically unprotected.
Because the law is unsettled here, contracts carry the weight: assignments from everyone building the system, clear terms with data suppliers, and terms for your AI product that tell customers who owns inputs and outputs.
What a contractor or agency agreement should say
Whether your developer is in Toronto or overseas, the contract should include:
- A present assignment of all IP in the deliverables to your company, not a promise to assign later.
- A moral rights waiver.
- A list of any pre-existing tools, libraries or code the contractor will reuse, with a licence to you for those pieces.
- Rules on open source, so copyleft components don’t end up in your product without your knowledge.
- Rules on which AI coding assistants may be used, and whether your code can be pasted into them.
- Confidentiality that survives the end of the engagement.
For offshore contractors, local law where they live may have different default rules. A clear written assignment and a stated governing law reduce the uncertainty. A mutual NDA doesn’t do this job; it protects information, not ownership.
Employees still need an agreement
The statutory rule for employees only covers work made in the course of employment. It doesn’t waive moral rights, and it doesn’t deal with inventions, side projects or confidential information. A written agreement settles those questions. See employee or contractor for how status is decided.
Why investors care
In due diligence, investors and acquirers usually ask for a list of everyone who contributed to the product and the signed agreements that moved their rights into the company. They may also ask about open source, data sources and third-party licences. Missing paperwork doesn’t always stop a deal, but it often becomes a closing condition or a delay. Keeping a simple IP register (who built what, under which agreement, using which data) makes that a short conversation. See getting investor-ready and hiring and equity.