Getting Started
Get up and running with the FreeFileTools API in just a few minutes. Follow these steps to make your first API call.
Step 1: Create an Account
Sign up for a free account at freefiletools.io. No credit card required. You can use your email or sign in with Google.
Step 2: Create an API Key
Once logged in, navigate to your Dashboard and go to API Keys. Click Create API Key to generate your key.
Your API key will look like: fft_abc123...
Important: Copy and store your API key securely. You will not be able to see the full key again after creation.
Step 3: Make Your First Request
Use your API key in the x-api-key header with every request. Here is a simple example using cURL to compress an image:
curl -X POST https://freefiletools.io/api/image-compress \
-H "x-api-key: fft_your_api_key_here" \
-F "file=@photo.jpg" \
-F "quality=80" \
-o compressed.jpgComplete Working Example
Here is a complete Node.js example that compresses an image and saves the result:
const fs = require("fs");
async function compressImage() {
const formData = new FormData();
formData.append("file", new Blob([fs.readFileSync("photo.jpg")]), "photo.jpg");
formData.append("quality", "75");
const response = await fetch("https://freefiletools.io/api/image-compress", {
method: "POST",
headers: {
"x-api-key": "fft_your_api_key_here",
},
body: formData,
});
if (!response.ok) {
const error = await response.json();
console.error("Error:", error);
return;
}
const buffer = Buffer.from(await response.arrayBuffer());
fs.writeFileSync("compressed.jpg", buffer);
console.log("Compressed image saved as compressed.jpg");
}
compressImage();Next Steps
Authentication -- Learn about API key authentication in detail.
API Reference: Image Tools -- Explore all image processing endpoints.
API Reference: PDF Tools -- Explore all PDF processing endpoints.
Code Examples -- Ready-to-use examples in multiple languages.