Get Started in Minutes

Free tier includes 1000 requests per day - perfect for development and small applications

1

Get API Key

Sign up for free and get your API key instantly

2

Make Request

Send HTTP requests to our conversion endpoints

3

Get Results

Receive precise conversions in JSON format

Get Free API Key

API Features

Everything you need for professional unit conversion integration

🎯

15-Decimal Precision

Laboratory-grade accuracy for scientific and engineering applications

📊

1000+ Units

Comprehensive coverage of length, weight, temperature, volume, and specialized units

Fast & Reliable

Sub-100ms response times with 99.9% uptime SLA

🔒

Secure & CORS

HTTPS encryption, CORS support, and rate limiting for security

📱

Any Language

Works with JavaScript, Python, PHP, Java, C#, Ruby, Go, and more

💰

Free Tier

1000 requests per day free - perfect for development and small apps

API Endpoints

Complete reference for all available endpoints

Base URL

https://api.precisionconvert.io/v1

All API requests should be made to this base URL with the appropriate endpoint path.

Authentication

Include your API key in the request header:

Authorization: Bearer YOUR_API_KEY

Convert Units

GET /convert
GET https://api.precisionconvert.io/v1/convert

Convert a value from one unit to another with 15-decimal precision.

Parameters

Parameter Type Required Description
value number Required The numeric value to convert
from string Required Source unit (e.g., "meters", "pounds", "celsius")
to string Required Target unit (e.g., "feet", "kilograms", "fahrenheit")
precision integer Optional Decimal places (1-15, default: 6)

Example Request

curl -X GET "https://api.precisionconvert.io/v1/convert?value=10&from=meters&to=feet&precision=6" \
  -H "Authorization: Bearer YOUR_API_KEY"
const response = await fetch('https://api.precisionconvert.io/v1/convert?value=10&from=meters&to=feet&precision=6', {
  headers: {
    'Authorization': 'Bearer YOUR_API_KEY'
  }
});
const data = await response.json();
console.log(data);
import requests

url = "https://api.precisionconvert.io/v1/convert"
params = {
    "value": 10,
    "from": "meters",
    "to": "feet",
    "precision": 6
}
headers = {
    "Authorization": "Bearer YOUR_API_KEY"
}

response = requests.get(url, params=params, headers=headers)
data = response.json()
print(data)
$url = "https://api.precisionconvert.io/v1/convert";
$params = http_build_query([
    'value' => 10,
    'from' => 'meters',
    'to' => 'feet',
    'precision' => 6
]);

$context = stream_context_create([
    'http' => [
        'header' => "Authorization: Bearer YOUR_API_KEY"
    ]
]);

$response = file_get_contents($url . '?' . $params, false, $context);
$data = json_decode($response, true);
print_r($data);

Response

200 OK
{
  "success": true,
  "result": {
    "value": 10,
    "from": "meters",
    "to": "feet",
    "converted_value": 32.808399,
    "precision": 6,
    "conversion_factor": 3.280839895013123
  },
  "timestamp": "2025-01-21T12:00:00Z",
  "request_id": "req_abc123"
}

List Available Units

GET /units
GET https://api.precisionconvert.io/v1/units

Get a list of all available units organized by category.

Parameters

Parameter Type Required Description
category string Optional Filter by category (length, weight, temperature, volume, etc.)

Example Response

200 OK
{
  "success": true,
  "units": {
    "length": [
      {"id": "meters", "name": "Meters", "symbol": "m"},
      {"id": "feet", "name": "Feet", "symbol": "ft"},
      {"id": "inches", "name": "Inches", "symbol": "in"}
    ],
    "weight": [
      {"id": "kilograms", "name": "Kilograms", "symbol": "kg"},
      {"id": "pounds", "name": "Pounds", "symbol": "lbs"}
    ]
  }
}

Batch Convert

POST /convert/batch
POST https://api.precisionconvert.io/v1/convert/batch

Convert multiple values in a single request for improved efficiency.

Request Body

{
  "conversions": [
    {"value": 10, "from": "meters", "to": "feet"},
    {"value": 25, "from": "celsius", "to": "fahrenheit"},
    {"value": 100, "from": "kilograms", "to": "pounds"}
  ],
  "precision": 6
}

Response

200 OK
{
  "success": true,
  "results": [
    {"value": 10, "from": "meters", "to": "feet", "converted_value": 32.808399},
    {"value": 25, "from": "celsius", "to": "fahrenheit", "converted_value": 77.0},
    {"value": 100, "from": "kilograms", "to": "pounds", "converted_value": 220.462262}
  ],
  "total_conversions": 3
}

Error Handling

Understanding API error responses and status codes

HTTP Status Codes

Status Code Description Common Causes
200 Success Request completed successfully
400 Bad Request Invalid parameters or missing required fields
401 Unauthorized Invalid or missing API key
429 Rate Limited Too many requests - upgrade plan or wait
500 Server Error Internal server error - contact support

Error Response Format

400 Bad Request
{
  "success": false,
  "error": {
    "code": "INVALID_UNIT",
    "message": "The unit 'invalid_unit' is not supported",
    "details": "Supported units can be found at /v1/units endpoint"
  },
  "timestamp": "2025-01-21T12:00:00Z",
  "request_id": "req_error123"
}

Rate Limits & Pricing

Flexible plans to meet your application's needs

Free Tier

$0
per month
  • 1,000 requests/day
  • 15-decimal precision
  • All unit categories
  • CORS support
  • Community support
Get Started Free

Pro Plan

$29
per month
  • 100,000 requests/day
  • Batch conversion API
  • Priority support
  • 99.9% SLA
  • Custom units support
Upgrade to Pro

Enterprise

Custom
pricing
  • Unlimited requests
  • Dedicated infrastructure
  • 24/7 phone support
  • 99.99% SLA
  • On-premise deployment
Contact Sales

SDKs & Libraries

Official libraries to get you started faster

📱

JavaScript/Node.js

npm install @precisionconvert/api
View Docs
🐍

Python

pip install precisionconvert
View Docs
🐘

PHP

composer require precisionconvert/api
View Docs

Java

<dependency>
  <groupId>io.precisionconvert</groupId>
  <artifactId>api</artifactId>
</dependency>
View Docs

Developer Support

Get help when you need it

📚

Documentation

Comprehensive guides, tutorials, and API reference

Browse Docs
💬

Community

Join our developer community for discussions and help

Join Discord
🎫

Support Tickets

Direct support for technical issues and questions

Contact Support