← Back to Blog
financedataindicators

Building a Custom Fear & Greed Index

How I built my own market sentiment indicator by combining VIX, momentum, and options data into a single readable gauge.

Why Build Your Own?

CNN has their Fear & Greed Index. It's useful, but it's also a black box. I wanted something I could understand, customize, and trust. So I built my own.

The Components

My index combines four key market signals:

1. VIX Level (30% weight)

The VIX measures implied volatility in S&P 500 options. When it spikes, people are scared. When it's subdued, complacency sets in.

  • Below 12: Extreme Greed
  • 12-15: Greed
  • 15-20: Neutral
  • 20-30: Fear
  • Above 30: Extreme Fear

2. Price Momentum (25% weight)

I look at SPY's 50-day moving average relative to its 200-day. The wider the gap, the stronger the trend.

  • SPY far above both MAs: Greed
  • SPY slightly above: Neutral
  • SPY below 50-day: Fear
  • SPY below both: Extreme Fear

3. Put/Call Ratio (25% weight)

The CBOE put/call ratio shows options positioning. More puts = more hedging = more fear.

  • Ratio < 0.7: Extreme Greed
  • 0.7-0.85: Greed
  • 0.85-1.0: Neutral
  • 1.0-1.2: Fear
  • Above 1.2: Extreme Fear

4. High Yield Spread (20% weight)

When credit spreads widen, risk appetite is declining. This is the "smart money" signal.

The Implementation

I pull data daily from:

  • Yahoo Finance API for price data
  • CBOE for VIX and put/call
  • FRED for credit spreads

Each component gets normalized to a 0-100 scale, then weighted and combined. The result is my personal sentiment gauge.

Why It Matters

This isn't about predicting the market. It's about understanding current conditions. High fear readings often (not always) precede good buying opportunities. Extreme greed readings suggest caution.

The key is using it as one input among many, not as a trading signal by itself.

Technical Details

Built with:

  • Next.js for the frontend
  • Framer Motion for the animated gauge
  • Python script for data collection
  • JSON file for daily updates

I update it manually each trading day. Eventually I'll automate it, but for now the manual process forces me to actually think about what's happening in markets.

Try It Yourself

Check out the Fear & Greed page to see the current reading. The gauge animates on load, and you can see historical values to track sentiment over time.

If you want to build your own version, start simple. Pick 2-3 indicators you understand and can easily track. The value is in the process, not the precision.