# ISO date difference

`iso-date-difference` · version 1.0.0 · Dates & times (UTC, ISO 8601) · free, no key needed

Whole days from start to end as a canonical integer string (end - start).

**Use when you need to: iso date difference · days between dates · date minus date.**

## Supported

- iso date difference
- days between dates
- date minus date

## Not supported

- business days
- timezones
- hours
- locale

## Behavior

- Both dates are strict YYYY-MM-DD as iso-date-add.
- days is the signed canonical integer string of (end - start) in civil days.
- Same date -> "0". end before start is negative.

## Input

- `start` (string, required): min length 10; max length 10
- `end` (string, required): min length 10; max length 10

## Output

- `days` (string, required)

## Limits

- year min: 1
- year max: 9999

## Example

Request input:

```json
{
  "start": "2026-09-10",
  "end": "2026-09-11"
}
```

Response:

```json
{
  "result": {
    "days": "1"
  }
}
```

## How to call it

### MCP

Connect `https://computefirst.net/mcp` ([setup](/docs#connect)), then call `execute` with:

```json
{
  "id": "iso-date-difference",
  "version": "1.0.0",
  "input": {
    "start": "2026-09-10",
    "end": "2026-09-11"
  }
}
```

### HTTP (no key)

```sh
curl -X POST https://computefirst.net/v1/tools/iso-date-difference/versions/1.0.0/execute \
  -H "Content-Type: application/json" \
  -d '{"start":"2026-09-10","end":"2026-09-11"}'
```

The machine-readable contract is at [/v1/tools/iso-date-difference/versions/1.0.0](/v1/tools/iso-date-difference/versions/1.0.0).

### CLI

```sh
node cli.mjs run iso-date-difference 1.0.0 --input input.json --base-url https://computefirst.net
```

Get the client at [/clients/cli/](/clients/cli/).

## Related tools

- [ISO date age](/tools/iso-date-age): Compute the calendar-aware elapsed years, months, and days between a birth date and an as-of date.
- [ISO date business days count](/tools/iso-date-business-days-count): Count the business days in an inclusive date range, skipping caller-supplied weekend weekdays and holidays.
- [ISO date range intersect](/tools/iso-date-range-intersect): Compute the intersection of two inclusive [start, end] date ranges.
- [ISO date range list](/tools/iso-date-range-list): Enumerate the dates in an inclusive [start, end] range stepped by a whole number of days.
- [ISO date weekday occurrences in range](/tools/iso-date-weekday-occurrences-in-range): List every date within an inclusive date range that falls on a given ISO weekday.
- [ISO date add](/tools/iso-date-add): Add a signed whole-day delta to a strict YYYY-MM-DD calendar date.
