Who owns the code? Rights and handover when you commission software in Switzerland
What the law says, what the agreement should say, and what a handover includes. Not legal advice.

Under Swiss law, the copyright in software starts with the person who wrote it, not with the company that paid for it. Who may use, change and pass on the code afterwards is decided by the law and by your agreement. This guide explains both, and what a handover can include. It is general information, not legal advice.
Who owns software you commission in Switzerland?
At first, the developer. The Copyright Act protects computer programs as works, and their author is the natural person who created them. Where an employee writes a program as part of their job, the employer alone may use it. So the rights sit with the people who wrote your software, or with their employer. You hold them only if they are assigned to you; a licence lets you use them while they stay with the developer.
- Software is protected without registration. "Computer programs are also works" (Art. 2 para. 3), and a work is protected "as soon as it is created" (Art. 29 para. 1). For computer programs, protection ends 50 years after the author's death (Art. 29 para. 2).
- The author is a person. "The author is the natural person who has created the work" (Art. 6). A company acquires copyright only from the people who created the work.
- Your own staff are a special case. Where a program is created "under an employment contract in the course of discharging professional duties", "the employer alone shall be entitled to exercise the exclusive rights of use" (Art. 17). That rule covers your employees. A company you commission is not your employee, so the rule does not move its rights to you.
- Holding a copy is not holding the rights. Owning a copy, even the original, "does not include the right to exploit the copyright" (Art. 16 para. 3).
- Rights pass by agreement, one by one. Copyright "is assignable" (Art. 16 para. 1), and assigning one right "does not include the assignment of other partial rights, unless such was agreed" (Art. 16 para. 2).
The Code of Obligations governs the contract itself. It defines a work contract as one where "the contractor undertakes to produce a piece of work and the customer undertakes to pay the contractor for that work" (Art. 363). Its articles on the work contract say nothing about copyright, so your agreement has to. The Swiss Federal Institute of Intellectual Property (IPI) notes that copyright can be assigned "in written or verbal form, or even tacitly". A written agreement is the one you can point to later.
Who owns code that AI wrote?
If an AI system wrote it on its own, possibly no one. Swiss copyright protects intellectual creations, and its author is a natural person. A study published by the IPI in 2024 says it "seems to be generally accepted in the Swiss legal literature" that works an AI system generates on its own are not protected. "This also applies to computer programs." Where AI is only a tool and a person's input remains substantial, the program is protected.
The study was written by researchers at the University of Zurich, and the IPI notes that the opinions are the authors' own. Two more points come from the IPI's deputy head of copyright legal services, in 2023. If an AI tool's output contains protected content from other works, "these parts of the output are still protected". And it is "important to check the terms of use" of the tool.
For your agreement, this means asking which tools are used to write the code, and who checks what they produce.
What should the agreement say?
Who holds which rights, from when, and what you receive. Because assigning one right does not carry the others with it, the agreement should name them: to use the software, to change it or have it changed, and to pass it on. It should also say when the rights pass, and what applies to code the developer brings from earlier work.
- An assignment or a licence. With an assignment, you become the holder of the rights. With a licence, in the IPI's words, "the uses of works are permitted but the rights still belong to the rights owner". An exclusive licence grants "the sole authority to use the work in the agreed manner".
- The right to change it. The author decides "whether, when and how the work may be altered" (Art. 11 para. 1). If you want the software changed later, by the same developer or by another one, the agreement should allow it.
- When the rights pass. For example on delivery, or on full payment.
- Earlier code and open-source parts. The last section covers them.
- What you receive at the end. The next section lists what a handover can include.
With us, ownership and what you receive at the end are agreed in the offer for each project, so you know both before anything is built. That holds whether you start with a first version or build it all at once.
What does a handover include?
Whatever the agreement lists. A complete handover of custom software can include the source code with its history, the structure of the database, the automated tests and the documentation. It can also include access to the accounts the software runs on, such as the domain. Agree the list in writing before the build starts, so nothing is left open at the end.
- The source code, with its history, so another developer can see how it grew and carry on.
- The database structure, so your data can be read and moved.
- The tests, so any later change can be checked against what already works.
- The documentation, so someone new can find their way.
- The accounts, such as the domain and the payment provider. Agree in whose name each one is.
What about tools the developer already had?
The agreement decides. A developer may bring code or building blocks written before your project. These can stay with the developer while you receive a licence to use them as part of your software. Open-source parts keep their own licences.
React, a library for building screens in the browser, is one example. Its MIT licence lets anyone use, copy and change it free of charge, on the condition that its notice "shall be included in all copies or substantial portions of the Software". Such parts stay under their own licence, so the agreement should list them.
A standard tool works the same way: you get a licence to use it, and its code stays with its maker. Custom software or an off-the-shelf tool? compares the two.
This article is general information about Swiss law, not legal advice. For a specific contract, the IPI suggests "an attorney who specialises in copyright or licensing agreements".
Sources
- Fedlex, "Federal Act on Copyright and Related Rights (Copyright Act, CopA)", SR 231.1, status as of 1 July 2025
- Fedlex, "Swiss Code of Obligations", SR 220, Art. 363, last amended 1 January 2026
- Swiss Federal Institute of Intellectual Property (IPI), "Copyright in businesses", accessed 20 October 2026
- IPI, "Can I assign my copyright?", accessed 20 October 2026
- IPI, "Rights assignment and licensing", accessed 20 October 2026
- IPI (Peter Georg Picht, Florent Thouvenin, Valerie Brunner, Joรซl Donzรฉ), "New Software Protection Approaches in a World (Co)shaped by AI", publication no. 13, October 2024
- IPI, "Artificial intelligence: can AI tools infringe copyright?", 17 February 2023
- React, "MIT License" (the licence file of the React repository), accessed 20 October 2026

