Calculate investment doubling time using the Rule of 72 approximation formula. Access via MCP in Cursor, Windsurf, and other AI coding tools, or REST API at `/v1/finance/rule-of-72`. Pass an interest rate (e.g., 8%) and get precise years to double your money. The rule divides 72 by the annual return rate for quick compound interest estimates.
curl "https://tinyfn.io/v1/finance/rule-of-72" \
-H "X-API-Key: YOUR_API_KEY"
const response = await fetch('https://tinyfn.io/v1/finance/rule-of-72', {
headers: { 'X-API-Key': 'YOUR_API_KEY' }
});
const data = await response.json();
console.log(data);
import requests
response = requests.get('https://tinyfn.io/v1/finance/rule-of-72',
headers={'X-API-Key': 'YOUR_API_KEY'})
data = response.json()
print(data)
Connect your AI agent (Claude, Cursor, Windsurf, etc.) to TinyFn's finance tools:
{
"mcpServers": {
"tinyfn-finance": {
"url": "https://tinyfn.io/mcp/finance",
"headers": {
"X-API-Key": "YOUR_API_KEY"
}
}
}
}
Most accurate for rates between 6-10%, with errors under 5%. For rates outside this range, logarithmic formulas provide better precision, but Rule of 72 remains useful for quick estimates.
The standard Rule of 72 assumes annual compounding. For monthly or daily compounding, use the adjusted Rule of 69.3 or precise compound interest formulas instead.
Rule of 72 uses simple division (72 ÷ rate), while exact calculations use ln(2)/ln(1+rate). Rule of 72 is faster but less precise at extreme rates.
The Rule of 72 works mathematically with negative rates, showing how long money loses half its value, though this scenario is less common in practice.
Use MCP integration to embed quick doubling estimates in investment analysis scripts. Combine with other finance tools for comprehensive portfolio modeling.