🔥 Firecrawl CLI
Command-line interface for Firecrawl. Search, scrape, interact, crawl, map, and run agent jobs directly from your terminal.
Installation
npm install -g firecrawl-cli
Or set up everything in one command (install CLI globally, authenticate, and add skills across all detected coding editors):
npx -y firecrawl-cli@1.16.2 init -y --browser
-y runs setup non-interactively
--browser opens the browser for Firecrawl authentication automatically
- skills install globally to every detected AI coding agent by default
Setup Skills and MCP
If you are using an AI coding agent like Claude Code, you can also install the skills manually with:
firecrawl setup skills
This installs skills globally across all detected coding editors by default. Use --agent <agent> to scope it to one editor.
Agent skills
The init command installs both sets of Firecrawl agent skills into AI coding agents (Cursor, Claude Code, Windsurf, etc.):
- CLI skills — teach agents how to use the Firecrawl CLI for live web work (search, scrape, interact, map, crawl, agent)
- Build skills — teach agents how to integrate Firecrawl into application code (choose endpoints, wire SDKs, set up API keys)
To reinstall skills manually:
firecrawl setup skills
To install the Firecrawl MCP server into your editors (Cursor, Claude Code, VS Code, etc.):
firecrawl setup mcp
Quick Start
Just run a command - the CLI will prompt you to authenticate if needed:
firecrawl https://example.com
Authentication
On first run, you'll be prompted to authenticate:
🔥 firecrawl cli
Search, scrape, and interact with the web
Welcome! To get started, authenticate with your Firecrawl account.
1. Login with browser (recommended)
2. Enter API key manually
Tip: You can also set FIRECRAWL_API_KEY environment variable
Enter choice [1/2]:
Authentication Methods
# Interactive (prompts automatically when needed)
firecrawl
# Browser login
firecrawl login
# Direct API key
firecrawl login --api-key fc-your-api-key
# Environment variable
export FIRECRAWL_API_KEY=fc-your-api-key
# Per-command API key
firecrawl scrape https://example.com --api-key fc-your-api-key
Self-hosted / Local Development
For self-hosted Firecrawl instances or local development, use the --api-url option:
# Use a local Firecrawl instance (no API key required)
firecrawl --api-url http://localhost:3002 scrape https://example.com
# Or set via environment variable
export FIRECRAWL_API_URL=http://localhost:3002
firecrawl scrape https://example.com
# Self-hosted with API key
firecrawl --api-url https://firecrawl.mycompany.com --api-key fc-xxx scrape https://example.com
When using a custom API URL (anything other than https://api.firecrawl.dev), authentication is automatically skipped, allowing you to use local instances without an API key.
Commands
scrape - Scrape URLs
Extract content from any webpage. Pass multiple URLs to scrape them concurrently -- each result is saved to .firecrawl/ automatically.
# Basic usage (outputs markdown)
firecrawl https://example.com
firecrawl scrape https://example.com
# Get raw HTML
firecrawl https://example.com --html
firecrawl https://example.com -H
# Multiple formats (outputs JSON)
firecrawl https://example.com --format markdown,links,images
# Save to file
firecrawl https://example.com -o output.md
firecrawl https://example.com --format json -o data.json --pretty
# Multiple URLs (scraped concurrently, each saved to .firecrawl/)
firecrawl scrape https://firecrawl.dev https://firecrawl.dev/blog https://docs.firecrawl.dev
Scrape Options