Switch from Firecrawl — Drop-In Replacement Guide
Looking for a Firecrawl replacement? Switch from Firecrawl to AlterLab in minutes. Our drop-in compatible API lets you migrate from Firecrawl with minimal code changes.
Quick Start
Near Drop-in Replacement
Before (Firecrawl)
curl -X POST https://api.firecrawl.dev/v1/scrape \
-H "Authorization: Bearer fc-xxxxxxx" \
-H "Content-Type: application/json" \
-d '{"url": "https://example.com", "formats": ["markdown"]}'After (AlterLab)
curl -X POST https://api.alterlab.io/api/fc/v1/scrape \
-H "Authorization: Bearer sk_live_xxxxxxx" \
-H "Content-Type: application/json" \
-d '{"url": "https://example.com", "formats": ["markdown"]}'What Changes
api.firecrawl.dev→api.alterlab.io/v1/scrape→/api/fc/v1/scrapefc-xxx→sk_live_xxxWhat Stays the Same
- Request body format
- Response structure
- Auth header format (Bearer token)
- Error response format
Compatibility Mapping
Endpoint Mapping
| Firecrawl Endpoint | AlterLab Equivalent | Support | Notes |
|---|---|---|---|
| POST /v0/scrape | POST /api/v0/scrape | Supported | Drop-in replacement, same request/response shape |
| POST /v0/crawl | POST /api/v0/crawl | Supported | Async crawl; poll via GET /api/v0/crawl/{jobId} |
| POST /v0/map | POST /api/v0/map | Supported | Returns links array of discovered URLs |
| GET /v0/crawl/{jobId} | GET /api/v0/crawl/{jobId} | Supported | Poll crawl status and results |
| DELETE /v0/crawl/{jobId} | DELETE /api/v0/crawl/{jobId} | Supported | Cancel a crawl |
| v1 Endpoints (current Firecrawl SDK version) | |||
| POST /v1/scrape | POST /api/fc/v1/scrape | Supported | Same as v0 — current Firecrawl SDK default |
| POST /v1/crawl | POST /api/fc/v1/crawl | Supported | Async crawl; poll via GET /api/fc/v1/crawl/{jobId} |
| POST /v1/map | POST /api/fc/v1/map | Supported | Returns links array of discovered URLs |
| GET /v1/crawl/{jobId} | GET /api/fc/v1/crawl/{jobId} | Supported | Poll crawl status and results |
| DELETE /v1/crawl/{jobId} | DELETE /api/fc/v1/crawl/{jobId} | Supported | Cancel a crawl |
Feature Mapping
| Firecrawl Feature | AlterLab Support | Notes |
|---|---|---|
formats: ["markdown"] | Supported | Returns clean markdown |
formats: ["html"] | Supported | Processed HTML |
formats: ["rawHtml"] | Supported | Original HTML |
formats: ["links"] | Supported | Extracted hrefs from page |
formats: ["screenshot"] | Partial | Requires JS rendering mode |
waitFor | Supported | Milliseconds delay |
timeout | Supported | Milliseconds (auto-converted) |
proxy: "stealth" | Supported | Maps to JS rendering mode |
extract | Supported | Structured data extraction |
onlyMainContent | Supported | Default behavior in AlterLab |
Authentication
The compatibility endpoint supports both Firecrawl-style and AlterLab-style authentication:
Firecrawl Style (Bearer)
Authorization: Bearer sk_live_xxxAlterLab Style (X-API-Key)
X-API-Key: sk_live_xxxUse Either Auth Method
Request Format
/api/v0/scrapeFirecrawl-compatible scrape endpoint. Accepts Firecrawl request format, returns Firecrawl response format.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| url | string | Required | The URL to scrape |
| formats | array | Optional | Output formats: markdown, html, rawHtml, links, screenshot, extract. Defaults to ['markdown']. |
| onlyMainContent | boolean | Optional | Only return main content (default behavior)Default: true |
| waitFor | integer | Optional | Wait time in milliseconds before fetchingDefault: 0 |
| timeout | integer | Optional | Timeout in millisecondsDefault: 30000 |
| proxy | string | Optional | Proxy mode: basic, stealth, auto |
| extract | object | Optional | Schema for structured data extraction |
Request Example
curl -X POST https://api.alterlab.io/api/v0/scrape \
-H "Authorization: Bearer sk_live_xxx" \
-H "Content-Type: application/json" \
-d '{
"url": "https://example.com",
"formats": ["markdown", "html"],
"waitFor": 1000,
"timeout": 30000
}'Response Format
Responses match Firecrawl's format with an optional alterlab extension containing additional metadata:
{
"success": true,
"data": {
"markdown": "# Example Domain\n\nThis domain is for use...",
"html": "<h1>Example Domain</h1><p>This domain is for use...</p>",
"rawHtml": "<!doctype html><html>...</html>",
"links": [
"https://iana.org/domains/example"
],
"metadata": {
"title": "Example Domain",
"description": "Example description",
"sourceURL": "https://example.com/",
"statusCode": 200
}
},
"alterlab": {
"tier_used": "1",
"credits": 1,
"response_time_ms": 842,
"cached": false
}
}Code Examples
import requests
# Minimal change: just update the base URL and API key
response = requests.post(
"https://api.alterlab.io/api/v0/scrape", # Changed from api.firecrawl.dev
headers={
"Authorization": "Bearer sk_live_xxx", # Your AlterLab key
"Content-Type": "application/json"
},
json={
"url": "https://example.com",
"formats": ["markdown", "html"]
}
)
data = response.json()
if data["success"]:
print(f"Markdown: {data['data']['markdown'][:100]}...")
print(f"Cost: {data['alterlab']['credits']}")
else:
print(f"Error: {data.get('error')}")SDK Migration
If you use the official Firecrawl Python or JavaScript SDK, you can point it at AlterLab with a one-line configuration change. AlterLab is compatible with the v1 SDK (`firecrawl-py` v4.x via V1FirecrawlApp, and `@mendable/firecrawl-js` v4.x via the v1 client).
Use the v1 SDK Client
/v2/* endpoints which are not yet supported. Use the v1 client class instead: V1FirecrawlApp in Python or the v1 constructor in JavaScript.Python SDK (firecrawl-py)
Compatible version: v4.x (using V1FirecrawlApp)
from firecrawl import V1FirecrawlApp
app = V1FirecrawlApp(api_key="fc-xxxxxxx")
# Scrape a page
result = app.scrape_url("https://example.com", params={
"formats": ["markdown", "html"]
})
print(result["data"]["markdown"])JavaScript SDK (@mendable/firecrawl-js)
Compatible version: v4.x (using v1 client)
import FirecrawlApp from '@mendable/firecrawl-js';
const app = new FirecrawlApp({ apiKey: 'fc-xxxxxxx' });
const result = await app.scrapeUrl('https://example.com', {
formats: ['markdown', 'html']
});
console.log(result.data.markdown);Why /api/fc in the URL?
The Firecrawl SDK appends /v1/scrape to your base URL. Setting api_url="https://api.alterlab.io/api/fc" makes the SDK hit /api/fc/v1/scrape which is AlterLab's Firecrawl v1 compatibility endpoint.
Unsupported SDK Features
The following Firecrawl SDK features are not available through the compatibility layer. Use AlterLab's native API for equivalent functionality where noted.
| SDK Feature | Status | AlterLab Alternative |
|---|---|---|
scrape_url() | Supported | Via v1 client + compat endpoint |
crawl_url() | Supported | Async crawl with polling |
map_url() | Supported | Returns flat URL list |
batch_scrape_urls() | Not Supported | Use /api/v1/batch |
extract() (async jobs) | Not Supported | Use formats: ["extract"] in scrape |
deep_research() | Not Supported | No equivalent |
generate_llms_txt() | Not Supported | No equivalent |
| WebSocket crawl streaming | Not Supported | Use polling via GET /crawl/{id} |
| v2 SDK client (default) | Not Supported | Use v1 client class |
Key Differences
1. Endpoint Path
AlterLab uses /api/v0/scrape instead of/v0/scrape due to API routing conventions.
2. Additional Response Data
AlterLab includes an optional alterlab object in responses with billing info, tier used, and performance metrics. This doesn't break Firecrawl compatibility.
3. Anti-Bot Capabilities
AlterLab has more aggressive anti-bot bypass capabilities with automatic tier escalation. Sites that fail on Firecrawl may succeed on AlterLab.
4. Pricing Model
AlterLab uses pay-as-you-go pricing instead of subscriptions. Check the pricing page for details.
AlterLab Extensions
While maintaining Firecrawl compatibility, you can also leverage AlterLab-specific features by using our native /api/v1/scrape endpoint:
Native Features
- Cost controls (max tier, force tier, max cost)
- OCR for image-based content
- PDF extraction
- Async/webhook mode
- Bring Your Own Proxy (BYOP) with 20% discount
- Batch scraping (up to 1,000 URLs)
- Scheduler with cron expressions
- Session management (authenticated scraping)
- Natural language extraction prompts
- Multi-format output (text, json, markdown, rag)
When to Use Native API
- Need advanced cost controls
- Processing PDFs or images
- Using webhooks for results
- Integrating with your own proxies
- Running scheduled/recurring scrapes
- Scraping sites that require login
Gradual Migration