Consider the circumstance where someone works for multiple customers and charges them on an hourly rate. This is pretty common. However, how should an hourly, contractual worker bill their customers when under the rare circumstance that they can do work just once, that is mutually beneficial for multiple customers?

In other words, assume that someone has two customers, A and B. Customer A and B have no relationship with one another. However, after you start working on both projects, you realize that you can consolidate about 20% of the work for both projects. Complete the work once, and 100% (of the 20%) can be mutually shared across both projects?

What is the ethical way of dividing the billing of this work among your customers? The initial, gut response is that you could/should let your customers know about the circumstance and only charge them half time, each. However, not all customers appreciate this model-- they want 100% of your work to belong to them.

For instance, imagine if you are a software engineer and you write freelance code. Some customers want you to write your code, strictly for them. I can understand this, especially if your code is contractually owned and proprietary to your customer. However, this isn't always plausible. There is a big difference between reusing a site layout, database structure or back-end, server code, and sharing a very low-level code base that takes care of simple tasks that your underlying development platform could have included, but hasn't. This is a common circumstance and re-writing the same code is considerably redundant and, frankly, unrealistic.

Another caveat is that the example of two customers, with a split requirement is a bit simple.

Again, take my coding example. You may realize that for a particular set of software projects, you could consolidate similar requirements into one code "framework". Neither customers project will use your framework to the fullness of it's potential. However, there is enough similarity to the two, that putting them together makes sense and, in the long run, could save both customers a bit of time.

What is the ethical way of handling these type of situations? I'm not a freelancer, but I do have to log hours for various, internal companies that I work for. It's not as big of a deal for me to perfectly track this (because all of these companies are owned by the same corporation), however, this is something that I have always questioned. Especially considering that the day may come where I become a freelance worker for these companies and will have to find a way to ethically divide up the work for billing.

6 Answers 6


This is something that should be spelled out in the contract you have with the clients. If the client wants to own absolutely every line of code, they have to pay for its production, you have to re-implement the same functionality for the other client, and you can't use a common framework. If the client wants a lower cost, they don't get to own every line of code, you get to leverage code and frameworks from prior clients, and it would generally be appropriate to split the billing 50/50.


Some customers want you to write your code, strictly for them. I can understand this, especially if your code is contractually owned and proprietary to your customer. However, this isn't always plausible.

No. If your contract states that you are to write your own code, strictly for them, then you write your own code, strictly for them. If you don't, and you re-use code/use code you made for them elsewhere, you can (and will, and should) be sued for breach of contract.

Now, if that's not the case, and you're allowed to re-use code segments, and the code is applicable to both clients' needs, I would have no issue charging them full for both. It would save you time, which saves them money. Charging them less than full-price for that shared time actually cheats you out of alot more than it might seem.

Think of it this way, if you own a lumber mill, and had a contract to provide planks of wood, and another to provide woodchips, you're not going to cut some planks, then throw out the leftover wood. you're going to use that leftover wood to reduce the amount of supplies you have to use to fulfill the woodchip contract's demands. You're not going to charge them less because some of their woodchips came from leftover pieces, that'd be silly. In the end, you end up with a bit more supplies than you normally would have, had gotten paid more, and did not charge the customers any more than they had originally expected to pay. Both sides are happy.

When you're coding, your 'supply' is your time.

Now, this is assuming this code applies to 2 clients at the same time, while you're writing it. After the fact, you should not charge the second customer full price to use code you've already developed some time in the past. In that case, you're charging for the code itself (not the work) and the upkeep costs.

  • 2
    This isn't technically always plausible. I'm not talking about a rock-solid contract for a major application for someone like NASA. Instead, most projects are completed using third-party software frameworks (most which are often free and open sourced.) If you find yourself writing a string method that reverses the order of text and capitalizing every other character for 10 separate projects, shouldn't you add something like that to your own framework and re-use it? That's the context I'm trying to discuss. These fine details aren't always discussed between a freelancer, and a small business.
    – RLH
    Jul 17, 2012 at 19:54
  • 4
    as i said, if your contract stipulates you're writing the code for the client, strictly for the client, then you can't re-use anything you write. open-source stuff...is a grey area. I personally would clear the use of open source stuff with the client (don't even ask if you can use open source components, just ask if you can use a specific component, and mention it is free.)
    – acolyte
    Jul 17, 2012 at 20:09
  • 2
    truly, it sounds like you should not agree to contracts stipulating you write code 'strictly for them.' i understand it's a pain, but if you aren't willing to fulfill those terms, you should have tried for a more flexible contract. i wouldn't blame you for trying
    – acolyte
    Jul 17, 2012 at 20:11
  • 3
    About re-using code: is there a formal definition of what amount of code is considered re-use? I'm sure that if I have i++; in my code for one client, I'm not forbidden from using that code segment ever again. How to avoid the heap paradox?
    – Val
    Oct 26, 2015 at 21:20
  • 1
    @vsz As a general guideline, if you copy/paste text or files to the new project, you are probably in trouble. If you rewrite the code from scratch, based on ideas that you remember from your last project, you are probably okay. If you have a large library of personal, reusable code, you may consider explicitly licensing that separately from the code that is produced as work-for-hire (possibly open source, possibly not; depends on your situation). If you need a more specific answer than that, then you need to consult a lawyer. Nov 18, 2015 at 17:44

I'm a little late to this answer, but there is a side that I don't see addressed: maintenance.

Even if you can reused the same ideas / algorithms (which take more time to conjure than it takes to bang out the code), I suggest billing the full time for creating them to both clients as that code will diverge and any thought process that went into creating it the first time will be re-evaluated the next time you compile that class.

This is not "ripping off" the customer, it is accepted practice in every field. Your building contractor pays less for the wood than you do because he's buying wood for you and 20 other clients every year. Likewise, your raw material (your brain) is being used in bulk for multiple clients as well and that is your advantage to them, not from them. That is why they come to you!


My opinion would be different based upon the contract you have with the clients.

If you are contracted for a fixed price for a particular product, there is nothing ethically wrong with refining your processes to increase your profit. For instance, if you built, say, a coffee tables and sold each for $100, but found a way to decrease the cost of making them by 20% you aren't required to pass those on to the customer for a discounted price. That's just good business and you pocket the profit.

If you are contracted for a estimated hours at an hourly rate, I would split the time between the two clients. The problem with this thinking, though, is how do you bill future clients that utilize this same framework? Or do they get it for free?

I tend to use the 'bleeding edge' kind of approach, meaning that the client with the first need of the framework will get the costs (assuming it is in the agreement anyways) and the future clients will get the benefit. Ethically, this works out fine in my mind because eventually the 2nd client will take the 'bleeding edge' on a different functionality while the 1st client will get the benefits. It makes billing less of a headache too because you don't get wrapped up in splitting up the costs for an infinite number of features that were built previously.


If the code belongs to you then you can charge your customers what ever they are willing to pay.

If you are creating a work for hire and the code belongs to them then sharing the code would be a breach of ethics. The code your wrote for company A belongs to company A. You might be able to get Company A to give you a release for that section of the code that would allow you to share it with the other customer. Many companies are willing to do a FOSS licence for systems that are not critical. But some companies are strongly proprietary of their work for hire. In addition if your work product belongs to Company A you may be limited in your ability to rewrite that code for Company B.


It is very common in some professions to bill the same time and material to multiple clients. Especially law, where taxis and flights can be booked to multiple cases as if they were the only case. You should base your behaviour on the generally accepted billing expectations for your region. A pricebook approach is prudent as there will be less variation from the estimate. What if you are wrong and being paid on a "Percentage of Completion" basis? Since the middle ages, prices have been set for use of shared resources (such as the only oven in town) regardless of the number of users. There is certainty in not messing with the prices.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .