---
title: "Number Base Converter"
method: POST
path: "/api/v1/tools/number-base-converter"
tags: ["tools"]
---

# Number Base Converter

`POST /api/v1/tools/number-base-converter`

## Request

- Base URL: `https://toolforte.com`
- URL: `https://toolforte.com/api/v1/tools/number-base-converter`
- Auth: HTTP bearer

Convert a whole number from one base to another, any base 2 to 36, and also return its binary, octal, decimal and hexadecimal forms. Exact for numbers of any size, no rounding.

## Request body

- object
  - `value` string
  - `fromBase` integer
  - `toBase` integer

## Response `200`

Successful result

- object
  - `ok` boolean
  - `data` object
    - `input` string
    - `fromBase` integer
    - `toBase` integer
    - `output` string
    - `negative` boolean
    - `binary` string
    - `octal` string
    - `decimal` string
    - `hexadecimal` string

## 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)
