{
    "name": "Date Calculator",
    "url": "https://calculators.geekmidst.com/calculators/date-calculator",
    "markdown": "https://calculators.geekmidst.com/calculators/date-calculator.md",
    "category": "Date, time & lifestyle",
    "description": "Find the date a number of days, weeks, months or years before or after any date, with the weekday and the total days in between.",
    "summary": "Pick a start date and add or subtract years, months, weeks and days. Months are counted on the calendar, so 31 January plus one month lands on the last day of February.",
    "also_called": [
        "Add days calculator",
        "Date plus days calculator"
    ],
    "applies_to": "Worldwide",
    "last_updated": "2026-10-29",
    "computation": "Results are computed in the visitor’s browser on the HTML page. This API describes the calculator; it does not compute results.",
    "inputs": [
        {
            "name": "start",
            "label": "Start date",
            "type": "date",
            "default": "2024-01-31"
        },
        {
            "name": "operation",
            "label": "Operation",
            "type": "segmented",
            "default": "add",
            "options": {
                "add": "Add",
                "subtract": "Subtract"
            }
        },
        {
            "name": "years",
            "label": "Years",
            "type": "number",
            "default": "0",
            "optional": true
        },
        {
            "name": "months",
            "label": "Months",
            "type": "number",
            "default": "1",
            "optional": true
        },
        {
            "name": "weeks",
            "label": "Weeks",
            "type": "number",
            "default": "0",
            "optional": true
        },
        {
            "name": "days",
            "label": "Days",
            "type": "number",
            "default": "0",
            "optional": true
        }
    ],
    "outputs": [
        {
            "key": "result_date",
            "label": "Resulting date",
            "format": "text"
        },
        {
            "key": "weekday",
            "label": "Day of the week",
            "format": "text"
        },
        {
            "key": "days_between",
            "label": "Calendar days from the start date",
            "format": "integer"
        }
    ],
    "formula": {
        "text": "Result = Start ± (years and months, on the calendar) ± (7 × weeks + days). If the day does not exist in the target month, the last day of that month is used.",
        "variables": {
            "Start": "the date you count from",
            "Years, months": "moved on the calendar first",
            "Weeks, days": "then added as exact numbers of days"
        }
    },
    "worked_example": {
        "inputs": {
            "start": "2024-01-31",
            "operation": "add",
            "years": "0",
            "months": "1",
            "weeks": "0",
            "days": "0"
        },
        "steps": [
            "31 January 2024 plus one month points to 31 February, which does not exist.",
            "2024 is a leap year, so the last day of February is the 29th.",
            "From 31 January to 29 February is 29 days."
        ],
        "result": "One month after 31 January 2024 is Thursday 29 February 2024."
    },
    "interpretation": "Use the weeks and days fields for exact deadlines (for example “within 30 days”) and the months field for calendar periods such as a six-month notice period. The two can give different answers near month ends.",
    "assumptions": [
        "Gregorian calendar, plain dates with no time of day or time zone.",
        "Years and months are applied before weeks and days."
    ],
    "limitations": [
        "Business days and public holidays are not skipped.",
        "Contracts and laws sometimes define month-end periods differently; check the wording that applies to you."
    ],
    "rules": null,
    "faqs": [
        {
            "question": "Is adding 30 days the same as adding one month?",
            "answer": "No. One month follows the calendar (28 to 31 days), while 30 days is always exactly 30 days. From 31 January, one month gives 28 or 29 February but 30 days gives 1 or 2 March."
        },
        {
            "question": "Does the result count the start day?",
            "answer": "No. Adding 1 day to Monday gives Tuesday. If you need to include the start day in a count, subtract one day from the number you enter."
        }
    ],
    "sources": [],
    "related": [
        {
            "name": "Date Difference Calculator",
            "url": "https://calculators.geekmidst.com/calculators/date-difference-calculator"
        },
        {
            "name": "Age Calculator",
            "url": "https://calculators.geekmidst.com/calculators/age-calculator"
        },
        {
            "name": "Time Calculator",
            "url": "https://calculators.geekmidst.com/calculators/time-calculator"
        }
    ],
    "disclaimer": null,
    "publisher": "GM¹X CalcVerse"
}