---
title: "Date Difference Calculator"
method: POST
path: "/api/v1/tools/date-difference-calculator"
tags: ["tools"]
---

# Date Difference Calculator

`POST /api/v1/tools/date-difference-calculator`

## Request

- Base URL: `https://toolforte.com`
- URL: `https://toolforte.com/api/v1/tools/date-difference-calculator`
- Auth: HTTP bearer

The time between two calendar dates: total days, weeks plus days, a years/months/days breakdown, hours, and the number of business days (Monday to Friday, no holidays). Order does not matter; the end date is excluded unless includeEndDate is true.

## Request body

- object
  - `startDate` string
  - `endDate` string
  - `includeEndDate` boolean

## Response `200`

Successful result

- object
  - `ok` boolean
  - `data` object
    - `start` string
    - `end` string
    - `startWeekday` string
    - `endWeekday` string
    - `swapped` boolean
    - `includeEndDate` boolean
    - `years` integer
    - `months` integer
    - `days` integer
    - `totalDays` integer
    - `totalWeeks` integer
    - `weeksAndDays` object
      - `weeks` integer
      - `days` integer
    - `totalHours` integer
    - `businessDays` integer

## Other responses

- `400`: Missing or invalid request fields
- `401`: Invalid or missing API key
- `429`: Monthly plan limit reached

---

[API](https://skmtc.dev/toolforte/apis/toolforte-api.md) · [All operations](https://skmtc.dev/toolforte/apis/toolforte-api/llms.txt) · [OpenAPI document](https://skmtc.dev/toolforte/apis/toolforte-api/revisions/4d814d484dfc?raw)
