Skip to content

Selling AI-generated code

Updated December 4, 202613 min read

You can sell code that you wrote with an AI tool when you have the right to distribute every file in the package and can give buyers the right to use it. Three separate questions decide that, and they’re easy to mix up: what your tool’s contract gives you, what copyright protects, and what other people’s licenses require of code that ended up in your project.

This article answers them with one invented example, Invoice Tracker, a small web app starter, in three states: built from scratch with a coding agent, carrying files the agent took from other projects, and rebuilt on a starter the seller bought. It covers common AI tool output terms, the US Copyright Office’s guidance on AI and copyright, and Kurodyne’s selling requirements. It isn’t legal advice, and it doesn’t decide who owns a particular project. The section on copyright in AI-generated code explains where the law is unsettled.

Can you sell AI-generated code?

Yes. Kurodyne reviews a product made with AI tools against the same listing standards as any other product, as Can I sell a product I made with AI? explains. This article goes deeper on code.

Three questions decide whether you can distribute the code and give buyers the right to use it. Each has its own source, and answering one doesn’t answer the others:

  • The tool’s contract: What did your AI tool’s vendor agree to give you? The contract can pass you the vendor’s own rights in the output, and nothing that belongs to someone else.
  • Copyright: Does the law protect the code as someone’s work, and whose? The answer decides what you could stop others from copying. It doesn’t change the other two answers.
  • Other people’s licenses: Does the package hold code or other material that someone else wrote? Its license applies to it whether you or an agent put it there.

It’s easy to settle one question and assume the rest. “The terms say I own the output” doesn’t mean that copyright protects the output, and neither statement covers a file that an agent copied from an open-source project.

Who owns AI-generated code?

Under major AI coding tools’ standard terms, the vendor generally assigns its rights in output to the account holder or claims no ownership in it. That settles ownership with the vendor only. Is AI-generated code protected by copyright? covers what the law protects.

Terms vary by plan, region, and enterprise agreement, and change over time, so check the current terms for your account:

Three points in vendor terms matter when you sell:

  • The vendor passes on only whatever rights it has. None of these terms guarantees that the output is protected by copyright, belongs to you alone, or is free of third-party material.
  • Output rights go to whoever holds the account. If you generated code on an employer’s or client’s plan, read Selling a side project while employed or Selling work built for a client before treating it as yours.
  • Standard output clauses generally allow selling generated code, subject to each vendor’s usage rules (such as restrictions on building competing models, non-commercial evaluation plans, or misrepresenting AI-generated output as human-written). Check the specific plan and usage policy that apply to your account.

In the United States, copyright protects what a person authored and doesn’t extend to purely AI-generated material, according to the US Copyright Office. Its report Copyright and Artificial Intelligence, Part 2: Copyrightability (opens in a new tab), published Jan 29, 2025, and listed on the US Copyright Office AI page (opens in a new tab), concludes, in its own words:

  • “The use of AI tools to assist rather than stand in for human creativity does not affect the availability of copyright protection for the output.”
  • “Copyright protects the original expression in a work created by a human author, even if the work also includes AI-generated material.”
  • “Copyright does not extend to purely AI-generated material, or material where there is insufficient human control over the expressive elements.”
  • “Whether human contributions to AI-generated outputs are sufficient to constitute authorship must be analyzed on a case-by-case basis.”
  • “Based on the functioning of current generally available technology, prompts do not alone provide sufficient control.”
  • “Human authors are entitled to copyright in their works of authorship that are perceptible in AI-generated outputs, as well as the creative selection, coordination, or arrangement of material in the outputs, or creative modifications of the outputs.”

These are a US agency’s conclusions about United States law. They aren’t court rulings, and they don’t decide the question in other countries, whose rules this article doesn’t cover. The Office also says it will watch “technological and legal developments to determine whether any of these conclusions should be revisited.”

How the conclusions apply to a codebase is unsettled. The report’s examples include images, a comic book, and a sound recording. It mentions code only in passing, and it doesn’t say how much review, editing, or direction makes you the author of a file from a coding agent. The Office’s answer is that each case is judged separately.

For a seller, the answer has three consequences:

  • It isn’t one of Kurodyne’s listing standards. A product made with AI meets the same standards as any other, and the three that decide most cases ask whether the product is your own work, whether you have the rights to sell it, and whether it works as described.
  • It decides what you can do about a copy. Only the owner of the rights in the copied material, or someone acting for the owner, can send a copyright notice, as Can I report someone for copying my product? explains. The parts of a product that copyright doesn’t protect give you nothing to claim there. Your buyers are a separate case: each one accepts the Kurodyne Commercial License at checkout, including its limits on sharing the product.
  • It shapes a US registration. The US Copyright Office’s registration guidance (opens in a new tab), effective Mar 16, 2023, says applicants “have a duty to disclose the inclusion of AI-generated content in a work submitted for registration and to provide a brief explanation of the human author’s contributions to the work.” Keep a record of what you did so you can write that explanation.

Can you sell an app you built with a coding agent?

Yes, when the tool’s terms leave the output to you, you’ve checked what the agent brought into the project, and the app is your own work. In its first state, Invoice Tracker looks like this:

invoice-tracker/
  README.md
  package.json
  package-lock.json
  src/                     Written with a coding agent from your spec, then reviewed and edited
  • The tool’s contract: You used your own plan, so the vendor’s standard output terms pass on whatever rights the vendor has, subject to its plan conditions. Note which tool, plan, and account you used.
  • Copyright: Applied to code, the US Copyright Office’s conclusions would protect your own expression: what you wrote, and your creative changes to and arrangement of what the agent produced. They wouldn’t extend protection to files that the agent wrote from your prompts alone and that you accepted unchanged. That’s our application of the report, which doesn’t address code directly, and the question is unsettled. Whether your contribution to a given file is enough is the case-by-case question, and this article can’t answer it for your project.
  • Other people’s licenses: The agent chose the dependencies in package.json, and each one keeps its own license. Check that their licenses fit what you sell under Which dependencies and files should I check?. You only need to include third-party license texts and notices for third-party code or assets that you actually bundle inside the ZIP file, as Third-party notices for code you sell explains.

Kurodyne’s listing standards apply as they do to any product: content generated in bulk doesn’t pass, and everything delivered has to work as the listing describes, so test what the agent produced the way a buyer would use it. What does each listing standard require? has the full list. To turn the app into a package, follow How to package and sell source code as an app starter.

Can you sell generated code that contains third-party material?

Yes, once each third-party file is identified and its license allows what you’re selling. In its second state, Invoice Tracker has three files that the agent took from other projects:

invoice-tracker/
  src/vendor/tiny-slug.js   Copied from an MIT-licensed project, header intact
  src/lib/pdf-table.ts      Starts with SPDX-License-Identifier: GPL-3.0-only
  src/lib/paginate.ts       Reproduced from another project, with no notice
  • The tool’s contract: It doesn’t clear these files. A vendor can pass on only its own rights, so nothing in its terms reaches rights that belong to another project’s author. OpenAI’s and GitHub’s terms say that generated code can carry third-party licenses.
  • Copyright: These files are other people’s work. The Copyright Office’s report asks whether new AI output gets protection, which is a different question from whether you may reuse an existing author’s code. The file’s license answers that one.
  • Other people’s licenses: Handle each bundled file as you would in any package. Keep the MIT file’s notice and ship its license text (for example, in THIRD_PARTY_NOTICES.md or an upstream license file), as Can I use MIT-licensed code in a product I sell? shows. The GPL-3.0-only file raises the conflict that Why can copyleft conflict with the Kurodyne Commercial License? describes, so replace or remove it, unless its author licenses it to you separately on terms that fit. The third file has no license you can point to: find its source and license, or replace it with code you can account for.

To find files like the first two, search the project for license and copyright notices:

Shell
grep -rniE --exclude-dir=node_modules --exclude-dir=.git --exclude=package-lock.json \
  "copyright|licen[sc]e|all rights reserved" .

Running this search on the example package prints:

./src/lib/pdf-table.ts:1:// SPDX-License-Identifier: GPL-3.0-only
./src/vendor/tiny-slug.js:3: * Copyright (c) 2020 Example Author
./src/vendor/tiny-slug.js:4: * Released under the MIT License.

It listed nothing for src/lib/paginate.ts. The search finds notices, not copied code, so an empty result doesn’t clear a file. The command skips the .git folder, installed dependencies, and the npm lockfile. Check dependencies through your dependency list, and change those names for another package manager.

For code without a notice, read the agent’s session record for what it fetched or was told to copy, and use your tool’s matching feature if it has one. GitHub’s documentation says Copilot can show references to matching public code (opens in a new tab), depending on the policy for your account or organization, and that its index doesn’t include code hosted outside GitHub. Replace any block you can’t trace.

Can you sell a purchased starter you modified with AI?

Not as source code, if you bought the starter on Kurodyne. Its license prohibits selling the starter or a modified copy as reusable material, and it makes no exception for changes made by an AI tool. In its third state, Invoice Tracker is rebuilt on a dashboard starter that the seller bought and the agent restyled, renamed, and extended:

invoice-tracker/
  src/dashboard/   The starter's layout and components, restyled by the agent
  src/auth/        The starter's sign-in code, with modules renamed
  src/invoices/    New files written with the agent
  • The tool’s contract: It covers what the tool generated and gives you no rights in the starter you gave it. That responsibility is yours under the vendor’s terms: OpenAI’s Terms of Use, for example, have you “represent and warrant that you have all rights, licenses, and permissions needed to provide Input.” The Kurodyne Commercial License lets a buyer give a purchased product to hosted AI tools that work for the buyer, on the conditions in Can contractors and hosted AI tools use a product I bought?.
  • Copyright: The starter’s seller keeps ownership of the starter. The license gives you permission to use it and doesn’t transfer the seller’s intellectual property. You own your original contributions to a finished product made with it, subject to the seller’s and third parties’ rights in their material, as Ownership and outputs (Kurodyne Commercial License) states.
  • Other people’s licenses: Here the license is the starter’s own. You must not sell, publish, or share the starter or a modified copy as a standalone product or as reusable material, place it in a competing template, or claim ownership of it, as Restrictions (Kurodyne Commercial License) lists. You may sell a finished product made with it that doesn’t expose the starter for reuse or stand in for buying it, such as a hosted Invoice Tracker service. Can I share or resell the product itself? covers that line.

A starter from anywhere else follows its own license, and Selling code that uses open source covers an open-source one.

Neither the license nor the tool’s terms says how much rewriting would make a file no longer a modified copy, so don’t rely on an agent’s rewrite to make the code yours. To sell source that’s built on someone else’s starter, get the owner’s written permission for reselling the source and for the uses the Kurodyne Commercial License gives your buyers, or rebuild those parts from your own work. What if a component’s terms don’t fit? describes that choice.

What do you promise when you sell code written with AI on Kurodyne?

You promise the same four things as for any product: that you own the material or hold enough rights to license it to buyers, that the product matches its description, that you’ve identified all third-party material and its obligations, and that the third-party terms are compatible with the commercial use you promise. You confirm them when you submit a product, under the Products section of the Terms of Use and the seller warranty in the Kurodyne Commercial License. Neither document has separate terms for products made with AI tools, and neither asks you to state that copyright protects the code. The Terms’ section on AI covers Kurodyne’s own AI features.

For AI-assisted code, check the rights you’re promising buyers: the tool’s terms leave the output to you, no file is someone else’s unlicensed work, and every bundled third-party file has its required license texts and notices under terms that fit. A person at Kurodyne reviews every listing against the listing standards before it goes live. That review isn’t a guarantee, as No warranties (Terms of Use) states, so the confirmation stays yours.

When you describe the product, keep to what you can support:

  • Don’t describe generated code as written by hand. A listing has to match the product, and some AI vendors prohibit representing AI-generated output as human-written.
  • Don’t promise that the code is protected by copyright, is exclusive to the buyer, or is free of every third-party claim. Generated output may not be unique, the US Copyright Office’s conclusions leave purely generated material unprotected, and the license each buyer receives is nonexclusive.
  • Don’t replace or narrow the license in your README. A listing, README, message, or bundled file can’t replace the Kurodyne Commercial License or add restrictions to it, as What do I agree to when I submit a product? explains.
  • Don’t tell buyers that your tool’s vendor will defend them. Commercial AI plans that include IP indemnification cover the vendor’s own customer under their plan conditions, not your buyers.

Under the Terms, sellers agree to defend Kurodyne against third-party claims that arise from their products, listings, or a breach of these promises about rights. Indemnification (Terms of Use) states the conditions.

What does a buyer of AI-generated code receive?

A buyer receives the same license as for any other product: permission to use, copy, modify, and build on the code for personal, internal business, and commercial purposes, under the license grant in the Kurodyne Commercial License. Kurodyne grants it on your behalf when payment and delivery complete, and it rests on your promise that you have the authority to license the product.

Three limits come with it:

  • Third-party material stays under its own license. The files and dependencies you identified as someone else’s can give buyers more rights or ask more of them, and buyers follow those terms for that material, as Third-party material (Kurodyne Commercial License) states. Your notices are how a buyer learns what else applies, so they have to be complete.
  • The license is permission to use the product. It doesn’t transfer your rights in it, and each buyer’s license is nonexclusive.
  • The license doesn’t say that copyright protects the code. Apart from the promises you make when you sell, the product comes with no other guarantee, including about infringing someone else’s rights, to the extent the law allows. Disclaimers and liability (Kurodyne Commercial License) states this.

Buyers can sell finished work that they make with the code, can’t resell the code as reusable source, and can work on it with their own hosted AI tools under the license’s conditions. Using purchased products for commercial and client work explains each rule.

What should you check before you submit?

Check the three questions for your own package, and keep the records that answer them:

  • Note which tool, plan, and account produced the code, and check the output terms for your plan. If the account is an employer’s or a client’s, settle ownership with them first.
  • Keep the version history that shows what you wrote, changed, and directed, with your specs and design notes. Under the US Copyright Office’s guidance, prompts alone don’t make you the author of the output, so these records show your process and don’t prove ownership.
  • Check for third-party files and include the required license texts and notices for any third-party code or assets you bundle in the package.
  • Take out any purchased file that you may use but not resell.
  • Write a listing that matches how the product was made and what it does, and list what it needs in Public requirements.

Keep private records, such as session logs, prompts, and contracts, out of the package. When the package and its notices are ready, follow Publish your first product.

Was this helpful?

Need more help? or contact Kurodyne support.