A swap is an agreement between two parties to exchange cash flows over a period of time, where at least one cash flow is determined by a variable such as interest rate, foreign exchange rate, or equity price. The most common type is an interest rate swap, where parties exchange interest payments on a notional principal amount at fixed and floating rates. Swaps allow users to align the risk characteristics of their assets and liabilities.