<!--
  Master Service Agreement (MSA) Template
  A DevShopVault template. Year: 2026.
  This is a practical template, not legal advice; have a lawyer review before use.
-->

# Master Service Agreement

**This Master Service Agreement ("Agreement")** is made as of [Effective Date] between:

- **Client:** [Client legal name], of [address] ("Client")
- **Agency:** [Agency legal name], of [address] ("Agency")

Each a "party" and together the "parties."

---

## 1. Structure and scope framework

This Agreement sets the terms that govern all work between the parties. Specific engagements are described in one or more Statements of Work ("SOW") that attach to and incorporate this Agreement. If a SOW conflicts with this Agreement, the SOW controls for that engagement only, and only where it says so expressly.

---

## 2. Term and renewal

This Agreement begins on the Effective Date and continues for [12] months. It renews automatically for successive [12] month terms unless either party gives written notice of non-renewal at least [30] days before the end of the current term. Termination of this Agreement does not by itself terminate an active SOW.

---

## 3. Fees and invoicing

- Fees for each engagement are set in the applicable SOW.
- Unless a SOW says otherwise, Agency invoices [monthly] and invoices are due net [10] days.
- Late amounts accrue interest at [1.5%] per month or the maximum allowed by law, whichever is lower.
- Fees exclude taxes. Approved third-party and AI provider costs are passed through to Client.

---

## 4. Confidentiality

Each party may receive non-public information of the other ("Confidential Information"). The receiving party will use it only to perform under this Agreement, protect it with reasonable care, and not disclose it except to personnel and contractors who need it and are bound by similar duties. These duties last for [3] years after disclosure, and indefinitely for trade secrets. Confidential Information does not include information that is public through no fault of the receiving party, independently developed, or lawfully received from a third party.

---

## 5. Intellectual property

On receipt of full payment for the relevant SOW, Agency assigns to Client all right, title, and interest in the custom deliverables created for Client under that SOW. Agency retains its pre-existing materials, tools, and know-how and grants Client a perpetual, non-exclusive license to use them as embedded in the deliverables. Open-source components remain under their own licenses.

---

## 6. Warranties

- Agency warrants that it will perform in a professional and workmanlike manner consistent with industry standards.
- Agency warrants that the custom deliverables are its original work or properly licensed.
- **AI output is probabilistic.** Where deliverables include AI-generated output, Agency does not warrant that the output is error-free, complete, or identical on repeated runs. AI features are warranted to meet the agreed evaluation criteria in the applicable SOW, not a standard of perfect output.
- Except as stated here, the services are provided "as is" and Agency disclaims all other warranties to the extent permitted by law.

---

## 7. Limitation of liability

To the maximum extent permitted by law, neither party is liable for indirect, incidental, special, or consequential damages, or for lost profits or data. Each party's total liability arising out of this Agreement is capped at the fees paid by Client under the applicable SOW in the [12] months before the event giving rise to the claim. These limits do not apply to breaches of confidentiality, infringement, or a party's willful misconduct.

---

## 8. Data protection

- Agency processes Client data only to provide the services and per Client's written instructions.
- Agency applies reasonable technical and organizational safeguards.
- Production data residency and permitted regions are set in each SOW.
- On termination, Agency returns or deletes Client data within [30] days on written request, except copies required by law.

---

## 9. Termination

Either party may terminate this Agreement or any SOW for material breach that is not cured within [15] days of written notice. On termination, Client pays for all work performed and accepted through the termination date. Sections on confidentiality, IP, warranties, liability, and payment survive termination.

---

## Optional AI-native clauses

### A. AI-generated code ownership

Custom code produced with the help of AI tools is treated as a deliverable under Section 5 and assigned to Client on full payment, to the extent such output is owned or ownable by Agency. Agency does not warrant exclusivity over non-original patterns that an AI tool may reproduce for other users.

### B. Training-data confidentiality

Agency will not submit Client Confidential Information to any AI tool or model provider whose terms allow that data to be retained for training or used to improve the provider's models, unless Client approves that tool in writing. Agency will prefer providers that offer no-retention or zero-training modes for Client data.

### C. Probabilistic-output warranty limit

The parties agree that AI features are non-deterministic. Acceptance and warranty for AI features are measured only against the evaluation set and thresholds defined in the applicable SOW. Variation within those thresholds on repeated runs is not a defect.

---

## Signatures

**Client**

Signature: ________________________  Name: [Name]  Title: [Title]  Date: __________

**Agency**

Signature: ________________________  Name: [Name]  Title: [Title]  Date: __________
