Math & Numbers
Convert between fractions and decimals with support for mixed numbers, improper fractions, and various decimal formats
Call this tool from your code in three languages.
curl -X POST 'https://api.elysiatools.com/en/api/tools/fraction-decimal-converter' \
-H 'Content-Type: application/json' \
-d '{"inputNumbers":"Enter fractions or decimals separated by commas, spaces, or newlines:\n1/2, 3 1/4, 5/8\n0.25, 3.75, 0.125\n1 2/3, 0.666, 7/3","conversionMode":"both","simplifyFractions":true,"showMixedNumbers":true,"maxDecimalPlaces":10,"decimalToFractionTolerance":1e-10,"showSteps":false}'Send a POST request with your inputs as JSON. File parameters require a separate upload first.
POST https://api.elysiatools.com/en/api/tools/fraction-decimal-converter| Name | Type | Required | Description |
|---|---|---|---|
| inputNumbers | textarea | Yes | — |
| conversionMode | select | Yes | — |
| simplifyFractions | checkbox | No | — |
| showMixedNumbers | checkbox | No | — |
| maxDecimalPlaces | number | No | — |
Add this tool to your Model Context Protocol server so AI agents can list and call it.
Add this block to your MCP client configuration:
{
"mcpServers": {
"elysiatools-fraction-decimal-converter": {
"name": "fraction-decimal-converter",
"description": "Convert between fractions and decimals with support for mixed numbers, improper fractions, and various decimal formats",
"baseUrl": "https://api.elysiatools.com/mcp/sse?toolId=fraction-decimal-converter",
"command": "",
"args": [],
"env": {},
"isActive": true,
"type": "sse"
}
}
}After connecting to the SSE endpoint, list the exposed tools:
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/list"
}Invoke the tool by its id, passing arguments built from its parameters:
{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/call",
"params": {
"name": "fraction-decimal-converter",
"arguments": {
"inputNumbers": "Enter fractions or decimals separated by commas, spaces, or newlines:\n1/2, 3 1/4, 5/8\n0.25, 3.75, 0.125\n1 2/3, 0.666, 7/3",
"conversionMode": "both",
"simplifyFractions": true,
"showMixedNumbers": true,
"maxDecimalPlaces": 10,
"decimalToFractionTolerance": 1e-10,
"showSteps": false
}
}
}| decimalToFractionTolerance |
| number |
| No |
| — |
| showSteps | checkbox | No | — |
Text result
{
"result": "Processed text content",
"error": "Error message (optional)",
"message": "Notification message (optional)",
"metadata": {
"key": "value"
}
}Questions or issues? Contact [email protected]