Maturity refers to the expiration date of a bond or similar debt security - meaning the date on which the bond's issuer must repay its holder. Maturity on bonds can vary from one day to 100 years while yield to maturity is calculated as the return on the bond over its whole life, although some bonds are recalled before their maturity date.
Corporate bonds and U.S. Treasuries are most commonly categorized based on their maturity - less than four years is considered short-term, 4-10 years medium term and 10+ years long-term. Callable bonds, by contrast, carry no maturity date and can be redeemed by the issuer at any time - usually after a call-protection period that prevents this redemption. Zero-coupon bonds sometimes have very long maturities and so sell at a steep discount to their par value.
Yield to maturity (YTM) is calculated as the rate of return on a bond held to maturity and is considered a long-term bond yield expressed at an annual rate. Its calculation involves factoring in market price, par value, coupon and maturity term, plus an assumption that all coupons will be re-invested.