{"success":true,"version":"v1","request":{"tool":"get_calculator_schema","calculator_id":"base-converter"},"result":{"entity_type":"calculator","id":"base-converter","calculator_id":"base-converter","canonical_url":"https://tttkmbb.com/math/base-converter","name":"Number Base Converter","title":"Number Base Converter – Binary, Octal, Decimal, Hexadecimal and Any Base 2–36","category":"math","category_name":"Math","tool_name":"convert_number_base","featured_mcp_tool":false,"description":"Converts an integer written in one base (2–36) to another, using exact arbitrary-precision arithmetic, and always shows the binary, octal, decimal and hexadecimal forms.","use_when":"You need to convert between binary, octal, decimal, hexadecimal or any positional base up to 36, including large integers.","do_not_use_when":"The value has a fractional part, you need Roman numerals (use roman-numeral) or byte/bit unit conversions (use data-storage).","inputs":[{"name":"value","label":"Number","type":"string","required":true,"description":"Integer written in the source base, e.g. 'ff' or '1010'. Letters a–z stand for digits 10–35 (case-insensitive); an optional leading '-' and the prefixes 0x, 0o, 0b are accepted.","example":"255"},{"name":"from_base","label":"From base","type":"integer","required":false,"default":10,"min":2,"max":36,"description":"Base of the input value.","example":10},{"name":"to_base","label":"To base","type":"integer","required":false,"default":2,"min":2,"max":36,"description":"Base of the result.","example":2}],"outputs":[{"name":"result","label":"Converted value","type":"string","decimals":4,"description":"The number written in to_base (digits above 9 as uppercase letters)."},{"name":"decimal","label":"Decimal","type":"string","decimals":4,"description":"Exact base-10 representation (a string so that very large values are not rounded)."},{"name":"decimal_value","label":"Decimal (number)","type":"number","decimals":0,"description":"Base-10 value as a number; omitted when it exceeds 2^53."},{"name":"binary","label":"Binary","type":"string","decimals":4,"description":"Base-2 representation."},{"name":"octal","label":"Octal","type":"string","decimals":4,"description":"Base-8 representation."},{"name":"hexadecimal","label":"Hexadecimal","type":"string","decimals":4,"description":"Base-16 representation."}],"input_schema":{"type":"object","properties":{"value":{"description":"Integer written in the source base, e.g. 'ff' or '1010'. Letters a–z stand for digits 10–35 (case-insensitive); an optional leading '-' and the prefixes 0x, 0o, 0b are accepted.","type":"string","examples":["255"]},"from_base":{"description":"Base of the input value.","type":"integer","minimum":2,"maximum":36,"default":10,"examples":[10]},"to_base":{"description":"Base of the result.","type":"integer","minimum":2,"maximum":36,"default":2,"examples":[2]}},"additionalProperties":false,"required":["value"]},"output_schema":{"type":"object","properties":{"result":{"description":"The number written in to_base (digits above 9 as uppercase letters).","type":"string"},"decimal":{"description":"Exact base-10 representation (a string so that very large values are not rounded).","type":"string"},"decimal_value":{"description":"Base-10 value as a number; omitted when it exceeds 2^53.","type":"number"},"binary":{"description":"Base-2 representation.","type":"string"},"octal":{"description":"Base-8 representation.","type":"string"},"hexadecimal":{"description":"Base-16 representation.","type":"string"}}},"formula":"value = Σ dᵢ × from_base^i (digits read right to left); the result digits are the remainders of repeated division by to_base","sources":[{"name":"Wikipedia – Radix","url":"https://en.wikipedia.org/wiki/Radix","type":"reference","retrieved_at":"2026-09-23"},{"name":"Wikipedia – Positional notation","url":"https://en.wikipedia.org/wiki/Positional_notation","type":"reference","retrieved_at":"2026-09-23"},{"name":"Wolfram MathWorld – Base","url":"https://mathworld.wolfram.com/Base.html","type":"reference","retrieved_at":"2026-09-23"}],"freshness":{"type":"static","max_age_seconds":null,"note":"Deterministic formula with fixed constants; results never go stale. Inputs supplied by the caller determine the output."},"examples":[{"name":"ff (hex) to decimal","inputs":{"value":"ff","from_base":16,"to_base":10},"expected":{"result":"255","decimal":"255","decimal_value":255,"binary":"11111111","octal":"377","hexadecimal":"FF"},"url":"https://tttkmbb.com/api/v1/calculate/base-converter?value=ff&from_base=16&to_base=10"},{"name":"1010 (binary) to hex","inputs":{"value":"1010","from_base":2,"to_base":16},"expected":{"result":"A","decimal":"10","decimal_value":10,"binary":"1010","octal":"12"},"url":"https://tttkmbb.com/api/v1/calculate/base-converter?value=1010&from_base=2&to_base=16"}],"faq":[{"q":"Are negative numbers supported?","a":"Yes, with a leading minus sign (sign-magnitude form). Two's-complement bit patterns are not interpreted."},{"q":"What about fractions like 0.1 in binary?","a":"Not supported; only integers are converted. Multiply by a power of the base first if you need fixed-point digits."}],"tags":["base converter","binary to decimal","decimal to binary","hex to decimal","octal","radix"],"related":[{"calculator_id":"modulo","reason":"Remainders used by the conversion algorithm."},{"calculator_id":"data-storage","reason":"Convert between bits, bytes and larger units."},{"calculator_id":"roman-numeral","reason":"A non-positional numeral system."}],"links":{"html":"https://tttkmbb.com/math/base-converter","markdown":"https://tttkmbb.com/math/base-converter.md","json":"https://tttkmbb.com/math/base-converter.json","api":"https://tttkmbb.com/api/v1/calculate/base-converter","schema":"https://tttkmbb.com/api/v1/calculators/base-converter","openapi":"https://tttkmbb.com/openapi.json","mcp":"https://tttkmbb.com/mcp"},"version":"v1","updated_at":"2026-09-23"},"timestamp":"2026-09-23T23:23:50Z"}