A kill fee only applies if it's written into your contract before the project starts, this is a planning estimate, not legal advice.
The calculator compares three numbers so you can pick the strongest justification for the invoice: a flat pre-start kill fee (a lower rate, since no work has started), a flat mid-work kill fee (a higher rate, since the client's cancellation interrupted committed work), and the pro-rated dollar value of the percentage of work actually completed.
The suggested amount is the larger of the mid-work flat rate and the pro-rated value, on the logic that a kill fee should never pay less than the value of work already delivered.
A kill fee is only enforceable, and only comfortable to invoice, if it was agreed to in writing before the project started. Without that clause, cancelling a project defaults to "pay for what was delivered," which usually undervalues the opportunity cost of turning down other work to hold a slot for this client.
Add a kill fee clause to every project contract from the start rather than negotiating one after a client has already announced they're cancelling, when leverage has shifted against you.
25% for pre-start cancellation and 50% for mid-project cancellation are common starting points, adjusted up for projects where holding the slot meant turning away other paid work.
Use the pro-rated value of work completed rather than the flat mid-work rate if it's higher, since a project that's 90% done has delivered nearly the full value regardless of the flat percentage on paper.
They're closely related: a kill fee typically applies to project-based work that stops partway through, while a cancellation fee more often applies to a scheduled booking or retainer that's called off before it starts.