Exposes five calculation tools via MCP: a safe expression evaluator supporting functions like sqrt, sin, and log with constants and variables; a unit converter covering length, weight, temperature, data, time, and speed; a statistics calculator for mean, median, variance, standard deviation, and correlation; a number formatter for currency, percentage, scientific notation, and different bases; and a percentage calculator for tips, discounts, and markup. Runs as a Node.js stdio server. Reach for this when you need Claude to handle numerical operations beyond simple arithmetic, whether converting 100 km/h to mph, calculating summary statistics on a dataset, or formatting financial figures with proper separators and currency symbols.
Public tool metadata for what this MCP can expose to an agent.
addAdds two numbers together2 paramsAdds two numbers together
firstNumbernumbersecondNumbernumbersubtractSubtracts the second number from the first number2 paramsSubtracts the second number from the first number
minuendnumbersubtrahendnumbermultiplyMultiplies two numbers together2 paramsMultiplies two numbers together
firstNumbernumberSecondNumbernumberdivisionDivides the first number by the second number2 paramsDivides the first number by the second number
numeratornumberdenominatornumbersumAdds any number of numbers together1 paramsAdds any number of numbers together
numbersarraymoduloDivides two numbers and returns the remainder2 paramsDivides two numbers and returns the remainder
numeratornumberdenominatornumbermeanCalculates the arithmetic mean of a list of numbers1 paramsCalculates the arithmetic mean of a list of numbers
numbersarraymedianCalculates the median of a list of numbers1 paramsCalculates the median of a list of numbers
numbersarraymodeFinds the most common number in a list of numbers1 paramsFinds the most common number in a list of numbers
numbersarrayminFinds the minimum value from a list of numbers1 paramsFinds the minimum value from a list of numbers
numbersarraymaxFinds the maximum value from a list of numbers1 paramsFinds the maximum value from a list of numbers
numbersarrayfloorRounds a number down to the nearest integer1 paramsRounds a number down to the nearest integer
numbernumberceilingRounds a number up to the nearest integer1 paramsRounds a number up to the nearest integer
numbernumberroundRounds a number to the nearest integer1 paramsRounds a number to the nearest integer
numbernumbersinCalculates the sine of a number in radians1 paramsCalculates the sine of a number in radians
numbernumberarcsinCalculates the arcsine of a number in radians1 paramsCalculates the arcsine of a number in radians
numbernumbercosCalculates the cosine of a number in radians1 paramsCalculates the cosine of a number in radians
numbernumberarccosCalculates the arccosine of a number in radians1 paramsCalculates the arccosine of a number in radians
numbernumbertanCalculates the tangent of a number in radians1 paramsCalculates the tangent of a number in radians
numbernumberarctanCalculates the arctangent of a number in radians1 paramsCalculates the arctangent of a number in radians
numbernumberradiansToDegreesConverts a radian value to its equivalent in degrees1 paramsConverts a radian value to its equivalent in degrees
numbernumberdegreesToRadiansConverts a degree value to its equivalent in radians1 paramsConverts a degree value to its equivalent in radians
numbernumberMath and calculation tools for AI agents, exposed via the Model Context Protocol (MCP).
calculateEvaluate math expressions safely (no eval). Supports arithmetic operators (+, -, *, /, ^, %), parentheses, functions (sqrt, abs, floor, ceil, round, log, ln, sin, cos, tan, min, max, pow), constants (pi, e), and named variables.
convert_unitsConvert between units across six categories:
statisticsStatistical analysis on datasets: mean, median, mode, variance, standard deviation, min, max, range, percentile, correlation between two arrays, and a full summary mode.
format_numberFormat numbers as: currency ($1,234.56), percentage, scientific notation, binary, octal, hexadecimal, significant figures, or with thousands separators.
percentage_calcCommon percentage operations: X% of Y, what percent X is of Y, percentage change between two values, tip calculator, discount calculator, and markup calculator.
npm install
npm run build
Add to your claude_desktop_config.json:
{
"mcpServers": {
"math-tools": {
"command": "node",
"args": ["path/to/mcp-math-tools/dist/index.js"]
}
}
}
Calculate: 2 * (3 + 4) ^ 2 returns 98
Convert: 100 from km/h to mph returns 62.137...
Statistics: summary of [1, 2, 3, 4, 5] returns mean, median, mode, variance, etc.
Format: 1234567.89 as currency returns $1,234,567.89
Percentage: 15% tip on 85.50 bill split 3 ways
MIT