> For the complete documentation index, see [llms.txt](https://docs.peach.ag/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.peach.ag/documentation/arc/launchpad/launchpad-pro/core-features/uniswap-v4-hooks/hook-behavior-and-fees.md).

# Hook Behavior and Fees

MemeHookV2 charges the launch's base Hook fee and additional Creator Tax. Read the launch's snapshotted settings. Snipe Tax applies only to Curve buys.

### Which asset pays the fee?

The Hook charges the output for Exact Input, or the input for Exact Output:

| Trade                               | Fee asset and effect                |
| ----------------------------------- | ----------------------------------- |
| Buy with Exact Input Quote          | Launch tokens, deducted from output |
| Sell with Exact Input launch tokens | Quote, deducted from output         |
| Buy with Exact Output launch tokens | Quote, added to input               |
| Sell with Exact Output Quote        | Launch tokens, added to input       |

Derive `zeroForOne` from the actual currency0/currency1 order. Buy/sell direction alone does not determine the swap mode.

### Calculation for router integrations

Let `A` be the absolute unspecified-currency delta before this Hook's adjustment. Let `b = hookFeeBps`; use `c = creatorBuyTaxBps` for a buy and `c = creatorSellTaxBps` for a sell:

| Mode         | Base fee                     | Creator Tax                  |
| ------------ | ---------------------------- | ---------------------------- |
| Exact Input  | `floor(A × b / 10000)`       | `floor(A × c / 10000)`       |
| Exact Output | `floor(A × b / (10000-b-c))` | `floor(A × c / (10000-b-c))` |

Exact Output uses one combined denominator for both fees. The combined rate must be below 100%. Each fee is rounded down separately in raw asset units.

For example, an Exact Output buy has a pre-Hook Quote input of 100,000,000 raw units and `b=c=100`. Each fee is 1,020,408 raw; final input is 102,040,816. With 6-decimal Quote, that is 102.040816 Quote. The router's maximum-input check must include both fees.

### Allocation and settlement

The base fee is split between platform and Creator using `protocolFeeShareBps`. Partner commission comes from the base platform portion; Creator Tax belongs entirely to Creator revenue.

`pendingCreator` already includes `pendingCreatorTax`. Track accrued amounts by pool and fee asset until [settlement](https://docs.peach.ag/documentation/arc/launchpad/launchpad-pro/core-features/uniswap-v4-hooks/fee-settlement-and-state). Core settlement converts eligible launch-token fees into Quote. See [Fees and Claims](https://docs.peach.ag/documentation/arc/launchpad/launchpad-pro/core-features/fees-and-claims).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.peach.ag/documentation/arc/launchpad/launchpad-pro/core-features/uniswap-v4-hooks/hook-behavior-and-fees.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
