joi vs yup

NPM Package Comparison - Which one should you use?

joi

🏆Most Popular🔄Recently Updated📘TypeScript

Object schema validation

View Repository →
npm install joi

yup

ðŸ“ĶSmallest⭐Most StarredðŸŠķLightweight📘TypeScript

Dead simple Object schema validation

View Repository →
npm install yup

Download Trends (Last 12 Weeks)

When to Choose Each

👉Choose joi if:

  • ✓You want the most battle-tested solution with a larger community
  • ✓You need actively maintained software with recent updates

👉Choose yup if:

  • ✓Bundle size is critical for your project
  • ✓You prefer fewer dependencies to reduce supply chain risk

Comparison

Metricjoiyup
Weekly Downloads18.6M10.5M
GitHub Stars21.2k23.7k
Bundle Size584.2 KB270.4 KB
Dependencies74
Last Updated5 days ago6 months ago
TypeScriptYesYes
LicenseBSD-3-ClauseMIT
Version18.1.11.7.1

Related Comparisons