Quant Sandbox
DerivativesPortfolio & RiskFixed IncomeCorporate FinanceStochastic ModelsGuide
Guide
Derivatives pricing
01Forwards, calls and puts02Combining positions03Arbitrage and the forward price04Put–call parity05The one-step binomial model06Risk-neutral probabilities07Multi-step trees and backward induction08American options and early exercise09Delta and hedging10Geometric Brownian motion11The Black–Scholes formula12The Greeks: gamma, vega, theta and rho13Implied volatility and the volatility smile14Stochastic volatility and the Heston model15Static replication: Breeden–Litzenberger and Carr–Madan16Exotic options: barriers, Asians and digitals
Portfolio & risk
01Returns and volatility02Diversification and correlation03The efficient frontier and the capital market line04Risk aversion and the optimal complete portfolio05CAPM, beta and the security market line06Performance measures: Sharpe, Treynor, Jensen and information ratio07Factor models and systematic risk08Value at Risk and expected shortfall
Fixed income
01Bond prices and yields02Duration and convexity03Immunization and duration matching04Spot rates, forward rates and the yield curve05Bond futures and the cheapest-to-deliver06Interest rate swaps07Callable bonds and negative convexity08Credit risk: default probabilities and credit spreads
Corporate finance
01Interest, compounding and discounting02Annuities, perpetuities and loan amortization03Net present value and internal rate of return04The weighted average cost of capital05Capital structure and the Modigliani–Miller theorems06Discounted cash flow valuation07Relative valuation with multiples08Real options: the value of flexibility
Stochastic models
01Random walks and Brownian motion02Probability spaces, σ-algebras and random variables03Filtrations, adapted processes and stopping times04Conditional expectation and martingales05Properties of Brownian motion06The reflection principle and first passage times07The Brownian bridge08The Itô integral09Itô's lemma10Kolmogorov equations and the Feynman–Kac formula11Change of measure and Girsanov's theorem12Monte Carlo option pricing13Simulating SDEs: the Euler–Maruyama scheme14Mean reversion: Ornstein–Uhlenbeck and Vasicek15Jumps and the Merton jump-diffusion model
Knowledge graph

© 2026 Quant Sandbox · A study aid for quantitative finance

Privacy & dataNo cookies

This site does not use cookies and asks for no personal data. It keeps a few small settings in your browser's local storage — your chosen theme and language, the sidebar layout, and your progress and answers in the Guides — so it remembers them on your next visit. This data never leaves your device; clearing your browser storage removes it. Inputs you change can also be captured in the page URL, so you can share or bookmark a specific setup. The site uses Vercel Web Analytics, a privacy-friendly, cookieless service that records only anonymous, aggregated usage (such as page views) without identifying you or tracking you across other sites.

Guide/Fixed income

Credit risk: default probabilities and credit spreads

Lesson 8 of 8 · 1 min read

Every bond in this track so far was assumed to pay exactly what it promised. A company, unlike a government that borrows in its own currency, can fail to pay. This lesson models that risk with one number per year, the hazard rate, prices a zero-coupon bond that may default, and shows where the extra yield on corporate bonds, the credit spread, comes from. It uses the discounting of "Interest, compounding and discounting", the yields of "Bond prices and yields" and the continuously compounded zero yields of "Spot rates, forward rates and the yield curve", and ends with the credit default swap, a close relative of the contracts in "Interest rate swaps".

Default and the default time

An issuer defaults when it misses a payment it owes. We describe default by a random default time τ\tauτ: the date at which the issuer fails. If τ>T\tau > Tτ>T, the issuer is still paying at TTT and a bond maturing at TTT is repaid in full. If τ≤T\tau \le Tτ≤T, the bond is not repaid in full.

The model rests on three assumptions, stated once here: the risk-free rate rrr is constant and continuously compounded; default is independent of interest rates; and a single parameter, the hazard rate, describes how likely default is.

Hazard rate and survival probability

The hazard rate (or default intensity) λ\lambdaλ is the probability of default per unit of time, given that the issuer has survived so far. Over a short interval dtdtdt,

P(t<τ≤t+dt∣τ>t)=λ dt.\mathbb{P}(t < \tau \le t + dt \mid \tau > t) = \lambda\,dt.P(t<τ≤t+dt∣τ>t)=λdt.

Let Q(t)=P(τ>t)Q(t) = \mathbb{P}(\tau > t)Q(t)=P(τ>t) be the survival probability up to ttt. To survive until t+dtt + dtt+dt, the issuer must survive until ttt and then not default in the next dtdtdt:

Q(t+dt)=Q(t) (1−λ dt)⟹dQdt=−λ Q(t),Q(0)=1.Q(t + dt) = Q(t)\,(1 - \lambda\,dt) \quad\Longrightarrow\quad \frac{dQ}{dt} = -\lambda\,Q(t), \qquad Q(0) = 1.Q(t+dt)=Q(t)(1−λdt)⟹dtdQ​=−λQ(t),Q(0)=1.

For a constant λ\lambdaλ the solution is an exponential, and the cumulative default probability is its complement:

Q(T)=e−λT,P(τ≤T)=1−e−λT.Q(T) = e^{-\lambda T}, \qquad \mathbb{P}(\tau \le T) = 1 - e^{-\lambda T}.Q(T)=e−λT,P(τ≤T)=1−e−λT.

This is the same algebra as continuous discounting: survival decays at rate λ\lambdaλ just as a discount factor decays at rate rrr. A fair picture is a light bulb with no memory: whatever its age, the chance it fails in the next hour is the same. For small λT\lambda TλT, 1−e−λT≈λT1 - e^{-\lambda T} \approx \lambda T1−e−λT≈λT, so a hazard rate of 2% means roughly a 2% chance of default per year.

Recovery and loss given default

Default rarely wipes out a bond. Creditors usually recover part of what they are owed from the issuer's remaining assets. The recovery rate RRR is the fraction of face value recovered, and 1−R1 - R1−R is the loss given default. Recovery for senior unsecured corporate bonds is often around 40%, which is why R=40%R = 40\%R=40% is a common default value.

We need to say when the recovery is paid. Here we assume recovery of face paid at maturity: if the issuer defaults before TTT, the holder receives RRR per unit of face at TTT. This keeps the payoff on a single date and makes the price easy to write down.

Pricing a defaultable zero-coupon bond

A risky zero-coupon bond with face 1 maturing at TTT pays 1 if τ>T\tau > Tτ>T and RRR if τ≤T\tau \le Tτ≤T. As in every pricing problem, the price is the discounted expected payoff with probabilities that make prices consistent (the risk-neutral probabilities of "Risk-neutral probabilities"; more on this below). Because default is independent of rates, the discount factor e−rTe^{-rT}e−rT comes out of the expectation:

Prisky=e−rT[ Q(T)⋅1+(1−Q(T))⋅R ]=e−rT[e−λT+(1−e−λT)R].P_{\text{risky}} = e^{-rT}\Big[\,Q(T)\cdot 1 + \big(1 - Q(T)\big)\cdot R\,\Big] = e^{-rT}\Big[e^{-\lambda T} + \big(1 - e^{-\lambda T}\big)R\Big].Prisky​=e−rT[Q(T)⋅1+(1−Q(T))⋅R]=e−rT[e−λT+(1−e−λT)R].

Two checks: with λ=0\lambda = 0λ=0 the bond never defaults and the price is the risk-free e−rTe^{-rT}e−rT; with R=1R = 1R=1 default costs nothing and the price is again e−rTe^{-rT}e−rT.

Credit spread

The continuously compounded yield of the risky zero is defined exactly as in "Spot rates, forward rates and the yield curve": y=−ln⁡Prisky/Ty = -\ln P_{\text{risky}}/Ty=−lnPrisky​/T. The credit spread is the extra yield over the risk-free rate:

s(T)=y−r=−1Tln⁡[e−λT+(1−e−λT)R]=−1Tln⁡[1−(1−R)(1−e−λT)].s(T) = y - r = -\frac{1}{T}\ln\Big[e^{-\lambda T} + \big(1 - e^{-\lambda T}\big)R\Big] = -\frac{1}{T}\ln\Big[1 - (1 - R)\big(1 - e^{-\lambda T}\big)\Big].s(T)=y−r=−T1​ln[e−λT+(1−e−λT)R]=−T1​ln[1−(1−R)(1−e−λT)].

The risk-free rate has dropped out: under these assumptions the spread depends only on λ\lambdaλ, RRR and TTT. If R=0R = 0R=0, the bracket is e−λTe^{-\lambda T}e−λT and the spread is exactly λ\lambdaλ.

The credit triangle

For small λT\lambda TλT, use 1−e−λT≈λT1 - e^{-\lambda T} \approx \lambda T1−e−λT≈λT and ln⁡(1−x)≈−x\ln(1 - x) \approx -xln(1−x)≈−x for small xxx:

s(T)≈−1Tln⁡[1−(1−R)λT]≈(1−R)λTT=λ (1−R).s(T) \approx -\frac{1}{T}\ln\big[1 - (1 - R)\lambda T\big] \approx \frac{(1 - R)\lambda T}{T} = \lambda\,(1 - R).s(T)≈−T1​ln[1−(1−R)λT]≈T(1−R)λT​=λ(1−R).

This is the credit triangle: spread, hazard rate and loss given default, any two of which give the third. In words, the spread pays for the expected loss per year: the chance of default per year times the fraction lost. The approximation is good when λT\lambda TλT is small (a few percent) and exact when R=0R = 0R=0; for high hazard rates or long maturities the exact spread falls below λ(1−R)\lambda(1 - R)λ(1−R).

Credit triangle: s≈λ (1−R)s \approx \lambda\,(1 - R)s≈λ(1−R). The spread is the expected loss rate: hazard rate times loss given default.

Worked example

Take λ=2%\lambda = 2\%λ=2%, R=40%R = 40\%R=40%, r=3%r = 3\%r=3% and T=5T = 5T=5 years.

Worked example

Price and credit spread of a five-year risky zero

  1. Survival probability to five years.

    Q(5)=e−0.02⋅5=e−0.1\displaystyle Q(5) = e^{-0.02 \cdot 5} = e^{-0.1}Q(5)=e−0.02⋅5=e−0.1=0.9048
  2. Default probability over the five years, in percent.

    1−Q(5)\displaystyle 1 - Q(5)1−Q(5)=9.52%
  3. Price per unit of face: survival pays 1, default pays R=0.4R = 0.4R=0.4 at maturity; discount with e−0.15≈0.8607e^{-0.15} \approx 0.8607e−0.15≈0.8607, the risk-free price.

    Prisky=e−0.15 [Q(5)+(1−Q(5))⋅0.4]\displaystyle P_{\text{risky}} = e^{-0.15}\,\big[Q(5) + (1 - Q(5)) \cdot 0.4\big]Prisky​=e−0.15[Q(5)+(1−Q(5))⋅0.4]=0.8116
  4. Continuously compounded yield of the risky zero.

    y=−ln⁡Prisky/5\displaystyle y = -\ln P_{\text{risky}}/5y=−lnPrisky​/5=4.176%
  5. Credit spread over the risk-free 3%; in basis points about 118.

    s(5)=y−r\displaystyle s(5) = y - rs(5)=y−r=1.176%
  6. The credit triangle, within about 2.4 basis points of the exact spread.

    λ(1−R)=0.02⋅0.6\displaystyle \lambda(1 - R) = 0.02 \cdot 0.6λ(1−R)=0.02⋅0.6=1.2%

With λ=10%\lambda = 10\%λ=10% instead, the 5-year exact spread is about 5.39% while the triangle gives 6%: the approximation degrades as λT\lambda TλT grows.

Spread against maturity

The figure has sliders for the hazard rate λ\lambdaλ (0% to 10%, default 2%), the recovery rate RRR (0% to 80%, default 40%) and the risk-free rate rrr (0% to 8%, default 3%). It plots the risk-free zero yield and the risky zero yield against maturity from 0.25 to 10 years. The readouts show the 5-year survival probability, the 5-year credit spread, the CDS premium λ(1−R)\lambda(1 - R)λ(1−R) and the 5-year risky zero-coupon price; at the defaults these are 90.48%, 1.18%, 1.20% and 0.8116. Set RRR to its maximum and note how the gap narrows; a recovery of 100% (the formula's limit) would remove the spread entirely. Raise λ\lambdaλ and the risky curve moves up. Note also that for a constant λ\lambdaλ the spread is nearly flat in maturity, drifting down slightly at long maturities where λT\lambda TλT is no longer small.

Risk-free and risky zero-coupon yieldsOpen in Bond Lab →
2.00%
00.1
40%
00.8
3.00%
00.08
Risk-free yieldRisky yield
5-year survival probability
90.48%
5-year credit spread
1.18%
CDS premium λ(1 − R)
1.20%
5-year risky zero price
0.8116

Risk-neutral and historical default probabilities

Reading the triangle backwards, a market spread sss and an assumed recovery RRR imply a hazard rate λ=s/(1−R)\lambda = s/(1 - R)λ=s/(1−R). This implied λ\lambdaλ is a risk-neutral default intensity: the one that makes the formula match market prices. It is typically well above the historical default rate observed for similar issuers. The spread is not only expected loss: investors also demand a premium for bearing default risk, which tends to strike in bad times for everyone, and for holding bonds that are harder to sell than government bonds (a liquidity premium). For pricing and hedging, use the implied λ\lambdaλ; for forecasting actual losses, use historical rates.

Credit default swaps

A credit default swap (CDS) is insurance against the default of a reference issuer. The protection buyer pays a fixed premium sCDSs_{\text{CDS}}sCDS​ per year on a notional until maturity or default, whichever comes first. If the issuer defaults, the protection seller pays 1−R1 - R1−R per unit of notional. Like the swaps of "Interest rate swaps", the fair premium sets the present values of the two legs equal. With continuous premium payments, constant λ\lambdaλ and rrr, and the protection paid at the moment of default:

sCDS∫0Te−(r+λ)t dt=(1−R)∫0Tλ e−(r+λ)t dt⟹sCDS=λ (1−R).s_{\text{CDS}}\int_0^T e^{-(r+\lambda)t}\,dt = (1 - R)\int_0^T \lambda\,e^{-(r+\lambda)t}\,dt \quad\Longrightarrow\quad s_{\text{CDS}} = \lambda\,(1 - R).sCDS​∫0T​e−(r+λ)tdt=(1−R)∫0T​λe−(r+λ)tdt⟹sCDS​=λ(1−R).

Here e−λte^{-\lambda t}e−λt is the probability the premium is still being paid at ttt, and λe−λt dt\lambda e^{-\lambda t}\,dtλe−λtdt the probability of default in [t,t+dt][t, t + dt][t,t+dt]. In this setting the triangle holds exactly for the CDS; the bond spread of 1.176% in the example differs slightly because its recovery is paid at maturity rather than at default. In practice, CDS premiums quoted for several maturities are turned into a term structure of hazard rates by bootstrapping, one maturity at a time, just as spot rates were extracted from bond prices.

Summary

  • The hazard rate λ\lambdaλ is the default probability per unit time given survival; for constant λ\lambdaλ the survival probability is e−λTe^{-\lambda T}e−λT.
  • With recovery RRR of face paid at maturity, Prisky=e−rT[e−λT+(1−e−λT)R]P_{\text{risky}} = e^{-rT}[e^{-\lambda T} + (1 - e^{-\lambda T})R]Prisky​=e−rT[e−λT+(1−e−λT)R].
  • The credit spread is approximately λ(1−R)\lambda(1 - R)λ(1−R), accurate when λT\lambda TλT is small; at λ=2%\lambda = 2\%λ=2%, R=40%R = 40\%R=40% the 5-year spread is 1.176% against 1.20%.
  • Implied (risk-neutral) hazard rates exceed historical default rates because spreads also contain risk and liquidity premia.
  • A CDS exchanges a premium for a payment of 1−R1 - R1−R on default; its fair premium is about λ(1−R)\lambda(1 - R)λ(1−R).
Try itPrice bonds and compare yields in the Bond Pricing lab →
2 questions on this lesson at the end of the series →
← PreviousCallable bonds and negative convexityBack to guides →Fixed income
Connections
Credit risk: default probabilities and c…
Open the full graph →
Labs for this lesson
Bond LabYield Curve