Copyright Engine
  • Monitoring
  • DMCA Takedowns
LoginStart my copyright
Copyright Engine

Any questions?

We're available Monday through Friday from 9am - 6pm CST

Product

  • Registration
  • Monitoring
  • DMCA Takedowns

Company

  • About
  • Contact

Resources

  • Blog
  • FAQ

Legal

  • Terms of Service
  • Privacy Policy
  • Legal Services Agreement

Copyright Engine provides information and software only. Use of Copyright Engine is subject to our Terms of Service, and Privacy Policy.

The Applicable Fees will be based on the specifics of your application but generally range from $44 and $125 and will be charged and collected at checkout.

  1. Home|
  2. Resource Center|
  3. Software and digital|
  4. Can You Copyright Code Written with AI Tools?

Can You Copyright Code Written with AI Tools?

Written byCopyright Engine

Published on November 20, 2026

Estimated Read Time: 6 minutes

Table of Contents

Is code written by AI copyrightable?Where AI coding assistant copyright lines get drawnPrompts alone don't make you the authorYour own code and edits do countSelection and arrangement can qualifyHow much human input is enough?Who owns code generated by AI?How do you document your human contributions?Registering AI-assisted codeYour next step: audit one repository this week
Can You Copyright Code Written with AI Tools?

Table of Contents

Is code written by AI copyrightable?Where AI coding assistant copyright lines get drawnPrompts alone don't make you the authorYour own code and edits do countSelection and arrangement can qualifyHow much human input is enough?Who owns code generated by AI?How do you document your human contributions?Registering AI-assisted codeYour next step: audit one repository this week

Key Takeaways

  • Prompting alone doesn't make you the author; the code you write, edit and arrange yourself is what earns protection.
  • Contract terms that say you own AI output can't create copyright where no human author exists.
  • Keep commit history, design notes and pull request reviews so you can show which parts you authored.
  • When registering, disclaim machine-generated code and claim your own code, modifications and arrangement.
  • Sort one repository into written, edited and generated code this week to see what you can claim.

AI coding assistant copyright protects only what a human authored. Here is how much of your AI-assisted code you can claim, who owns it, and how to document it.

Yes, you can copyright code written with AI tools, but only the parts a human authored. Under U.S. law, AI coding assistant copyright protects your original logic, structure, edits and selections. It doesn't protect lines the model produced on its own from a prompt. The more you shape the code, the more you own.

That answer surprises a lot of developers. You type a prompt, a tool returns two hundred working lines, and it feels like yours. The Copyright Office sees it differently, because copyright has always required a human author.

Don't panic, though. Almost nobody ships pure autocomplete output. You read it, rewrite it, wire it into a larger system and decide what stays. That work counts, and this guide shows where the line sits and how to prove your side of it.

Is code written by AI copyrightable?

Pure machine output isn't. Copyright attaches to original works of authorship under 17 U.S.C. § 102, and the Copyright Office and the courts read "authorship" to mean a human being. The D.C. Circuit upheld that rule in the Thaler case, which involved a work the claimant said an AI system created on its own.

Code is treated like any other literary work. If the expressive choices came from a model, there's nothing for you to claim in those choices. If the expressive choices came from you, there is.

The broader rule for AI output of every kind lives in our explainer on the Copyright Office's position on AI-generated content. Here we stick to code.

Where AI coding assistant copyright lines get drawn

The Copyright Office's guidance on AI says the question is how much human control there was over the final expression. Three situations come up again and again.

Prompts alone don't make you the author

Typing "build me a login form with rate limiting" tells a tool what you want. It doesn't dictate how the code is written. The Office has said that even detailed prompts generally don't give the user enough control over the output to count as authorship. If your whole contribution is the request, expect the resulting code to sit in the unprotected column.

Your own code and edits do count

When you write a function yourself and ask a tool to suggest a refactor, your original lines stay protected. When you take a generated block and rework its control flow, rename and restructure it, or merge it with your own modules, your modifications can qualify as human authorship in AI generated code. The protection covers what you contributed, not the untouched machine text around it.

Selection and arrangement can qualify

A program is more than its individual lines. Choosing which suggestions to accept, how modules relate, how data flows and how the pieces are organized can be a creative arrangement. The Office recognizes protection for human selection and arrangement of material, even when some of that material isn't protectable by itself. Mechanical or obvious choices won't carry much weight, but a thoughtful architecture can.

How much human input is enough?

There's no percentage. No rule says 30 percent human code or 60 percent. The Office looks case by case at whether a person determined the expressive elements of the work.

A rough way to think about it:

  • Likely thin protection: you prompted, accepted the output, and committed it unchanged.
  • Stronger protection: you designed the architecture, wrote core modules by hand, and used the tool to draft boilerplate that you then reviewed and edited.
  • Strongest protection: the tool is a fancy autocomplete, and you wrote and shaped nearly everything.

Also remember that copyright covers expression, not ideas. Even fully human code doesn't protect the underlying method or functionality, which is a separate question from authorship.

Who owns code generated by AI?

This is where people mix up two different questions. Copyright ownership asks who holds the legal rights. Contract terms ask what the tool's provider lets you do with the output.

Many AI coding tools say in their terms that you own the output, or that they assign their rights to you. That's a contract promise between you and the vendor. It can't create copyright where the law finds no human author. So you might own the code in a contractual sense while the machine-written portions remain unprotected against copying by others.

The human-written portions belong to you as the author, unless someone else has a claim. If you're a salaried developer, the company likely owns your work, and we explain why in who owns code written by an employee. If you hired outside help, ownership depends on a signed agreement, as covered in freelance developer ownership. Using an AI tool doesn't change either rule.

How do you document your human contributions?

Records matter more now than they used to. If you ever register the work or enforce it, you may need to show which parts you wrote. Start these habits today.

  1. Commit often, with real messages. A git history that shows you writing, then editing, tells a clear story.
  2. Flag generated blocks. A short comment or commit tag marking where a tool drafted code makes later disclosure easy.
  3. Keep design notes. Architecture diagrams, tickets and specs show the creative decisions you made before any tool touched the code.
  4. Save the review trail. Pull request comments showing what you changed or rejected are good evidence of selection and modification.
  5. Note the tool and version. If you must describe the AI contribution later, you'll have the facts.

None of this is paperwork for its own sake. It's the difference between confidently describing your authorship and guessing.

Registering AI-assisted code

You can still register. Registration is what lets you sue for infringement in federal court, and it's explained in our hub on whether you need to register to be protected.

The catch is disclosure. The Copyright Office's registration guidance says applicants must tell it when a work contains more than a minimal amount of AI-generated material, and must exclude that material from the claim. In practice, you describe your claim as the human-authored code, modifications and arrangement, and you disclaim the machine-generated portions.

Fees are the same as for any work. A Single Application costs $45 and works only if you're the sole author and the work isn't made for hire. A Standard Application costs $65 and fits everything else. Because AI-assisted work usually calls for a careful authorship statement, many developers prefer a Standard Application.

If wording the claim in eCO feels risky, Copyright Engine prepares and files the application for you and helps you describe your authorship accurately. For truly murky cases, such as code that's mostly generated, talk to a copyright attorney first.

Your next step: audit one repository this week

Pick the project you care most about and sort it into three buckets: code you wrote, code you substantially edited, and code you accepted as generated. Add notes to your repository describing each bucket, then check your commit history against it.

That one exercise tells you what you can actually claim, what you'd need to disclaim, and where a rewrite might be worth it. If the claimable part is meaningful, register it. The official Copyright Office AI resources are worth bookmarking, since this guidance keeps being updated.

Sources

  1. U.S. Copyright Office. Copyright and Artificial Intelligence.
  2. U.S. Copyright Office. Registration Portal and Guidance.
Back to the article

Frequently asked questions

Yes, if the work contains more than a minimal amount of AI-generated material. The Copyright Office asks applicants to identify it and exclude it from the claim, so you describe your authorship as the human-written code, your modifications and your arrangement. Leaving out required disclosure can put the registration at risk later.

No. Using a tool doesn't cancel the protection on code you wrote yourself. It only means the portions a model generated without meaningful human control aren't protected. Your original code, your edits to generated text and your selection and arrangement of the pieces remain yours as the author.

If the code is purely machine-generated, there may be no copyright for you to enforce against copiers. Contracts, trade secret protection or license terms might still help in some situations. Parts you authored, such as your own functions and original structure, stay protected and can be enforced.

It depends on the country. Many jurisdictions also expect a human author, though some, like the United Kingdom, have special rules for computer-generated works. Because the Berne Convention gives you protection in member countries mostly on local terms, check local law or ask an attorney before relying on it abroad.

Probably not until you've added meaningful human work. A claim covering only a small human portion gives limited protection for the fee. If the human share is real, such as your architecture, edits and original modules, registration can make sense. A copyright attorney can help with borderline cases.

Keep reading

Do You Need to Register a Copyright to Be Protected?

Do you need to register copyright to be protected? No, your work is covered the moment you create it, but automatic protection has sharp limits. Here's when…

Who Owns Code Written by an Employee?

Employer ownership of employee code is the default under U.S. copyright law when a developer writes software within the scope of the job. Here's where that r…

Who Owns Code Written by a Freelance Developer?

Who owns code written by a freelancer? Usually the freelancer, until you have a signed assignment. Here's how work for hire really works for contractors and…