{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://askcalculators.com/calculator/protein-calculator/schema.json",
  "title": "Protein Calculator inputs",
  "description": "Estimate a weight-based daily protein range for general adult, older-adult, endurance, strength, calorie-deficit, or pregnancy contexts.",
  "type": "object",
  "properties": {
    "unitSystem": {
      "title": "Weight units",
      "type": "string",
      "default": "metric",
      "enum": [
        "metric",
        "imperial"
      ],
      "x-optionLabels": {
        "metric": "Kilograms",
        "imperial": "Pounds"
      }
    },
    "weightKg": {
      "title": "Body weight",
      "type": "number",
      "default": 70,
      "minimum": 20,
      "maximum": 500,
      "x-step": 0.1,
      "x-suffix": "kg",
      "x-showWhen": {
        "field": "unitSystem",
        "equals": "metric"
      }
    },
    "weightLb": {
      "title": "Body weight",
      "type": "number",
      "default": 154,
      "minimum": 44,
      "maximum": 1100,
      "x-step": 0.1,
      "x-suffix": "lb",
      "x-showWhen": {
        "field": "unitSystem",
        "equals": "imperial"
      }
    },
    "scenario": {
      "title": "Activity or life-stage reference",
      "type": "string",
      "default": "general",
      "enum": [
        "general",
        "older",
        "endurance",
        "strength",
        "weightLoss",
        "pregnancy"
      ],
      "x-optionLabels": {
        "general": "General healthy adult",
        "older": "Older adult reference",
        "endurance": "Endurance training",
        "strength": "Strength training",
        "weightLoss": "Calorie deficit / weight loss",
        "pregnancy": "Pregnancy reference"
      }
    },
    "meals": {
      "title": "Meals or feedings per day",
      "type": "number",
      "default": 4,
      "minimum": 1,
      "maximum": 10,
      "x-step": 1,
      "multipleOf": 1
    }
  },
  "required": [
    "unitSystem",
    "scenario",
    "meals"
  ],
  "allOf": [
    {
      "if": {
        "properties": {
          "unitSystem": {
            "const": "metric"
          }
        },
        "required": [
          "unitSystem"
        ]
      },
      "then": {
        "required": [
          "weightKg"
        ]
      }
    },
    {
      "if": {
        "properties": {
          "unitSystem": {
            "const": "imperial"
          }
        },
        "required": [
          "unitSystem"
        ]
      },
      "then": {
        "required": [
          "weightLb"
        ]
      }
    }
  ],
  "additionalProperties": false,
  "x-askcalculators": {
    "version": "2.0.0",
    "calculatorUrl": "https://askcalculators.com/calculator/protein-calculator/",
    "queryExample": "https://askcalculators.com/calculator/protein-calculator/?unitSystem=metric&weightKg=70&scenario=general&meals=4",
    "migrationStatus": "migrated",
    "reviewStatus": "pending",
    "pageStatus": "live",
    "workStatus": "pending",
    "migratedDate": "2026-08-25",
    "formula": {
      "expression": "Protein range = body weight (kg) × scenario-specific grams-per-kilogram interval."
    },
    "quality": {
      "availability": "live",
      "technicalReviewRecord": "/reviews/protein-calculator.json",
      "qualifiedReview": "pending",
      "qualifiedReviewer": null,
      "qualifiedReviewDate": null,
      "formulaVersion": "2.0.0",
      "referenceCoverage": "references-listed",
      "releaseTestScope": "Catalog and regression checks are not a professional formula audit; consult release evidence.",
      "historicalMetadataDate": "2026-08-25",
      "historicalMetadataNotice": "The imported date is not evidence of a completed human review."
    },
    "outputs": {
      "proteinRange": {
        "title": "Estimated daily protein range",
        "type": "string",
        "x-format": "text",
        "x-primary": true
      },
      "midpoint": {
        "title": "Range midpoint",
        "type": "number",
        "x-format": "number",
        "x-suffix": " g/day",
        "x-digits": 0
      },
      "perMeal": {
        "title": "Midpoint per meal",
        "type": "number",
        "x-format": "number",
        "x-suffix": " g",
        "x-digits": 0
      },
      "energyRange": {
        "title": "Energy from protein",
        "type": "string",
        "x-format": "text"
      },
      "factor": {
        "title": "Weight factor",
        "type": "string",
        "x-format": "text"
      }
    }
  }
}
