The average and the trade answer different questions
A chart says the token’s ten-minute average price is 1.10. Your swap preview is worse. Neither observation necessarily contradicts the other: the first summarizes a history, while the second depends on current reserves, fees, routing and your trade size.
This distinction matters whenever a protocol uses a pool-derived price to value collateral. The number needs a stated observation window and a reason that the chosen market is appropriate. Calling it an oracle does not remove the underlying market’s limitations.
A ten-minute example with unequal durations
Imagine a price of 1.00 for nine minutes followed by 2.00 for one minute. A simple time-weighted arithmetic average is (1.00 × 9 + 2.00 × 1) ÷ 10 = 1.10. Taking the unweighted average of just those two observed price values would instead give 1.50.
That fictional calculation explains time weighting; it is not a claim about a particular token or a live pool. You also need to specify the quote direction. The average of reciprocal prices is generally not the reciprocal of the average, so reversing a pair is not a harmless display change.
What Uniswap v2 accumulates
Uniswap v2’s oracle design accumulates price multiplied by elapsed time. Comparing cumulative observations and dividing their difference by the interval produces an average over that interval. The observation procedure matters as much as the final division.
This is a description of v2, not a universal implementation recipe for every AMM version. Other designs can use different accumulated quantities and averaging conventions. Read the exact implementation rather than treating every product labeled TWAP as the same mathematical object.
Smoothing has a cost: it remembers older conditions
A longer interval can dilute a short price disturbance, but it also includes more old information after a genuine market move. A shorter interval reacts faster while providing less temporal smoothing. There is no window length that automatically solves every market and application.
Liquidity and the value an attacker could extract matter too. A pool-derived average is not manipulation-proof merely because time appears in its formula. An integration needs to examine the economics of the chosen market and what decisions depend on its answer.
Ask for an executable quote separately
When comparing a trade, request output for the same input amount, chain and destination at approximately the same time. Keep the historical reference price separate from price impact, execution protections and costs. A one-token reference observation cannot promise execution for a thousand-token order.
For an oracle-backed application, record the pool, quote orientation, window, observation method and failure behavior. For a personal swap comparison, record the actual route and minimum output. These are complementary records, each useful for a different question.



