Skip to content

Sell your source code

Indiemaker · Updated 17 November 2026

In short

To sell source code you choose between licensing it, where you keep ownership and can sell it again, and assigning it, where the buyer becomes the owner. Buyers check that you hold the rights to every line, that it builds and runs from the repository, and what it would cost them to write it themselves.

Code with no customers attached is the hardest software asset to price and the easiest to get wrong legally. When you sell source code, the buyer is not paying for files, which can be copied forever. They are paying for a right: the right to use it, or the right to own it. Which of those you are offering has to be settled before anything else on this page matters.

Licence or assignment: two different sales

Licence Assignment
Who owns the code afterwards You The buyer
Can you sell it again Yes, unless the licence is exclusive No
Can you keep using it Yes Only if the buyer licenses it back to you
Typical buyer Someone who wants a starting point or a component Someone who wants the product as their own
Document Licence agreement Assignment agreement, usually inside an asset purchase agreement

An assignment is a one-off transfer of ownership, and it is what a buyer on a business-for-sale site normally expects. If you want to keep rights for yourself, for example to reuse a library in other projects, say so in the listing and have it written into the agreement. The glossary entry on IP assignment explains what the document does. The wording needs a lawyer, because what makes an assignment valid differs by country.

What a buyer checks in a repository

  • That it is yours to sell. Who wrote it, under what arrangement. Code written for an employer or a client may belong to them. Code from contractors needs their written assignment.
  • What else is in there. Open-source dependencies and their licences, copied snippets, paid components, fonts, images and datasets. Some open-source licences place conditions on how the combined work can be distributed or sold, and a careful buyer will read the list.
  • That it runs. Whether a fresh clone builds, passes its tests and starts, following only the README.
  • The history. A commit history shows how the code came to exist and who touched it. A single commit containing everything invites questions.
  • Secrets. Keys, passwords and customer data committed at any point in the history.
  • Whether it has been sold before. If copies or licences are already out there, the buyer needs to know how many and on what terms.

What to have ready before you list

  1. A written statement of what is on offer: assignment or licence, exclusive or not, and anything you keep.
  2. A list of every contributor, with signed assignments from anyone who is not you.
  3. A dependency list with licences. Most package managers can generate one.
  4. A clean history: rotate any credential that was ever committed, and remove real customer data.
  5. A README that takes a stranger from clone to running, and a note on what the hosting costs.
  6. A working demo the buyer can try, on a live address, with test data.
  7. An honest list of what is unfinished or known to be broken.

Item six matters more than it looks. Buyers on Indiemaker are looking for a working product they can try and then own, not an archive of files, so a repository with nothing running is a hard sell. The general preparation list is in what you need before you list.

How source code changes hands, and why it is awkward

The mechanics are short. On most code hosting services a repository can be moved to another account, or the buyer can be given a full copy with its history. The legal transfer is the signed assignment or licence.

The awkward part is that code cannot be handed back. Once a buyer has read a repository they have the thing, whether or not they pay. That is why sellers do not give full access early, and why buyers will not pay before they have seen enough. The usual way through is in stages:

  1. Before an offer: a live demo, the README, the dependency list, architecture notes and a screen-share walkthrough.
  2. After an offer is accepted and a confidentiality agreement signed: read access for a short, agreed inspection window.
  3. Funds placed in escrow.
  4. Repository transferred and the assignment signed.
  5. Buyer confirms it matches what was inspected, and the money is released.

After the transfer, an assignment normally means you delete your copies and stop using the code, except for anything you carved out in writing. Agree that in advance.

How pricing is approached when there is no revenue

There is no Indiemaker guide range for code on its own. The guide ranges apply to trailing annual profit, and code without customers has none. We also do not publish sold prices.

The method buyers use is replacement cost: what it would cost them to produce the same thing. Suppose a buyer estimates 200 hours of work at $50 an hour, so $10,000 to rebuild. They will not pay $10,000, because yours is not written the way they would write it, they have to learn it, and they carry the risk that something is wrong inside. They will offer some fraction, and how large a fraction depends on how well the code is documented, how current it is and how exactly it matches what they need.

Two things raise the figure. Anything hard to reproduce: a dataset, a trained model, an integration that needed approval from a third party. And any sign of demand: users, sign-ups, traffic. Once those exist you are no longer selling code alone, and the pieces are valued together. If the code already earns money, it is a business, and selling a SaaS is the better page.

How to sell source code on Indiemaker

Listings are priced from $1,000 to $500,000, and every published listing has been checked against our listing standards. Buyers can open a limited number of listings a month for free, and message you and make an offer from an opened listing.

Payment and handover run through Escrow.com. The buyer's money is held until the transfer is done, which is the protection both sides need in a sale where the asset cannot be returned. The seller pays a success fee out of the sale and the buyer pays Indiemaker no fee. Rates are on /pricing.

When the rights are clear and the demo is running, list your project.

Related: ip-assignment, replacement-cost, asset-based-valuation, software-escrow

List it when the numbers are ready.

One form, the same fields every buyer reads, from $1,000 to $500,000.