Automated Discounted Cash Flow (DCF) valuation model for any publicly traded company. Enter a ticker and get a full valuation with WACC decomposition, FCF projections, and sensitivity analysis — the same framework used in investment banking.
- Fetches real financials from Yahoo Finance — free cash flow history, market cap, debt, beta, shares outstanding
- Calculates WACC using CAPM for cost of equity and historical interest expense for cost of debt
- Projects FCF forward using a user-adjustable growth rate (defaults to historical CAGR)
- Discounts to present value and adds terminal value via the Gordon Growth Model
- Outputs intrinsic value per share vs current market price with upside/downside
- Sensitivity table — intrinsic value across a grid of growth rate and WACC combinations (standard IB output)
git clone https://github.com/akshatg10104/autodcf.git
cd autodcf
pip install -r requirements.txt
streamlit run app.pyPython 3.10+ required.
Enter any valid ticker (AAPL, MSFT, JPM, etc.) and click Run DCF. Adjust assumptions in the sidebar:
- FCF growth rate — projected annual growth for years 1–N (defaults to historical CAGR)
- Terminal growth rate — perpetuity growth rate after projection period (typically ~2.5%)
- Projection years — 3 to 10 years
- Risk-free rate — 10-year Treasury yield
- WACC override — manually set the discount rate if needed
| Component | Method |
|---|---|
| Cost of Equity | CAPM: Rf + β × ERP (ERP = 5.5%, Damodaran) |
| Cost of Debt | Interest Expense / Total Debt × (1 − Tax Rate) |
| WACC | Weighted by market-value capital structure |
| Terminal Value | Gordon Growth Model: FCF × (1+g) / (WACC − g) |
| Intrinsic Value | (PV of FCFs + PV of TV − Net Debt) / Shares Outstanding |
autodcf/
├── app.py # Streamlit dashboard
├── utils/
│ ├── data_fetch.py # yfinance wrapper
│ ├── wacc.py # WACC components
│ └── dcf.py # DCF engine + sensitivity analysis
└── requirements.txt
Disclaimer: For educational purposes only. Does not constitute investment advice.