Skip to content

jlafauci97/fair-rent-engine

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

Fair Rent Engine

A free, data-driven tool that tells NYC renters what their rent should actually be.

Live: lucidrents.com/fair-rent-engine


What It Does

A renter searches for any NYC building. The tool returns:

  1. A quantitative fair price range based on the Zillow ZORI rent index, validated against comparable listings
  2. A multi-factor quality adjustment where building violations, 311 complaints, crime data, litigation history, and rent stabilization status each algorithmically raise or lower the fair rent
  3. A visual breakdown showing exactly how much each factor contributed to the determination (e.g. "HPD Violations: -5.2% / -$174/mo")
  4. A seasonal negotiation signal based on ZORI monthly trends and days on market
  5. Better options nearby — higher-rated comparable buildings in the same ZIP with scores, amenities, and median rents

The Pricing Model

The fair rent is not a single number from a single source. It's a 6-step algorithmic calculation where each step adjusts the price based on a different data signal:

Step 1: Base Price
  └─ Median of comparable StreetEasy listings (same beds, sqft ±25%, 0.5mi)
  └─ Fallback: Zillow ZORI index for this ZIP code

Step 2: ZORI Validation
  └─ If comp median diverges >20% from ZORI → blend 70/30

Step 3: Amenity Adjustment (+/- up to 20%)
  └─ Doorman +9%, Elevator +5%, In-unit laundry +4%, Gym +2%, etc.
  └─ Walkup penalty -5% (inferred if no elevator)

Step 4: Seasonal Factor
  └─ Current ZORI / 12-month average ZORI
  └─ High season (>1.03x) vs low season (<0.97x)

Step 5: Quality Adjustment (NEW — the key differentiator)
  ├─ HPD Violations:     above-average → -3% to -10% discount
  ├─ 311 Complaints:     above-average → -2% to -6% discount
  ├─ Neighborhood Crime:  Grade F → -7%, Grade A → +4% premium
  ├─ Active Litigations:  harassment case → -8% discount
  └─ Rent Stabilization:  deregulation trend → -3% discount
  └─ Total clamped to [-20%, +10%]

Step 6: Final Fair Price
  └─ base × amenity × seasonal × (1 + quality_adjustment)
  └─ Fair range: ±5% of fair price

Data Sources (100% Free, Public)

Source What It Provides Access
Zillow ZORI ZIP-level monthly rent index Free CSV download
NYC Open Data — HPD Violations Class A/B/C violations per building Free API
NYC Open Data — 311 Complaints Complaint type, volume per address Free API
NYC Open Data — HPD Litigations Active/closed housing court cases Free API
NYC Open Data — NYPD Crime Crime by ZIP, category, YoY trend Free API
Lucid Rents Database Building scores, amenities, rents, reviews Proprietary (400K+ buildings)
NYC RGB / nycdb Rent stabilization status Free

Tech Stack

  • Framework: Next.js 16 (App Router, React 19)
  • Styling: Tailwind CSS v4
  • Animations: Framer Motion
  • Charts: Recharts + custom SVG gauges
  • Database: Supabase (PostgreSQL)
  • APIs: NYC Open Data SODA REST (no auth required)
  • Deployment: Vercel

File Structure

src/
├── app/
│   ├── fair-rent-engine/page.tsx          # Page entry point
│   └── api/fair-rent/analyze/route.ts     # API: orchestrates all data + pricing
├── components/fair-rent/
│   ├── FairRentApp.tsx                    # Client root (input → loading → results)
│   ├── InputForm.tsx                      # Building search + rent entry
│   ├── LoadingSequence.tsx                # Animated step-by-step loading
│   ├── ResultsShell.tsx                   # Results layout with staggered reveals
│   ├── PricingVerdict.tsx                 # SVG gauge: overpriced/fair/good deal
│   ├── FairPriceCard.tsx                  # Price range bar + methodology
│   ├── QualityBreakdown.tsx               # Factor-by-factor breakdown card
│   ├── SeasonalSignalCard.tsx             # Season meter + negotiation tip
│   ├── BuildingScorecardGrid.tsx          # 2×2 grid: violations, 311, stab, legal
│   ├── NeighborhoodSafetyCard.tsx         # Crime grade ring + trend
│   ├── TenantRightsCallout.tsx            # Conditional rights alerts
│   ├── ComparablesCard.tsx                # Better options nearby
│   └── types.ts                           # TypeScript interfaces
├── lib/fair-rent/
│   ├── pricing-model.ts                   # 6-step pricing algorithm
│   ├── constants.ts                       # Multipliers, thresholds, ZIP populations
│   ├── zori-lookup.ts                     # ZORI CSV parser + ZIP lookup
│   ├── nyc-open-data.ts                   # HPD, 311, litigations, crime fetchers
│   ├── rent-stabilization.ts              # Stabilization check via Supabase
│   ├── streeteasy-scraper.ts              # Comp scraping (fallback)
│   └── comparables.ts                     # Comparable buildings from DB
public/data/
│   └── zori-nyc.csv                       # Zillow rent index (106 NYC ZIPs)

Who It's For

  • First-time NYC renters who don't know if a price is fair
  • Low-income renters and immigrants who lack broker access
  • Anyone evaluating an apartment who wants the same data a sophisticated broker has

Why It Matters

NYC renters negotiate leases almost completely blind. Landlords know exactly how long a unit has been sitting, what comparable units rented for, and whether the building has code violations. Tenants have Zillow and intuition.

The Fair Rent Engine closes that information gap — for free, using 100% public data.


Built by Lucid Rents — rental intelligence for NYC, LA, Chicago, Miami, and Houston.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors