Firecrawl Tools
Firecrawl provides powerful web scraping, search, crawling, and data extraction capabilities for AI applications.Installation
Environment Variables
Available Tools
| Tool | Description |
|---|---|
scrapeTool | Scrape a single URL |
searchTool | Search the web |
mapTool | Discover URLs on a site |
crawlTool | Crawl multiple pages |
batchScrapeTool | Scrape multiple URLs |
extractTool | Extract structured data |
Quick Start
Scrape Tool
Scrape a single URL and get clean markdown content.Crawl Tool
Crawl multiple pages starting from a URL.Using with AI SDK Directly
Batch Scraping
Scrape multiple URLs efficiently.Extract Structured Data
Extract specific data from web pages.Response Format
Scrape Result
Crawl Result
Advanced Example
Error Handling
Best Practices
Guidelines
Guidelines
- Use appropriate tool - Scrape for single pages, crawl for multiple
- Set limits - Always set crawl limits to avoid excessive API usage
- Filter content - Use includeTags/excludeTags to get relevant content
- Handle async jobs - Use pollTool for crawl and batch operations
- Cache results - Store scraped content to avoid repeated requests

