npx skills add https://github.com/firecrawl/cli --skill firecrawl网络爬取、搜索和页面交互的 CLI 工具。返回适用于 LLM 上下文窗口的优化 Markdown 内容。
运行 firecrawl --help 或 firecrawl <command> --help 以获取完整的选项详情。
必须已安装并完成身份验证。使用 firecrawl --status 进行检查。
🔥 firecrawl cli v1.8.0
● 通过 FIRECRAWL_API_KEY 完成身份验证
并发数: 0/100 个任务 (并行爬取限制)
积分: 剩余 500,000
如果尚未准备就绪,请参阅 rules/install.md。有关输出处理指南,请参阅 rules/security.md。
firecrawl search "query" --scrape --limit 3
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
遵循此升级模式:
map --search 找到正确的 URL,然后抓取它。| 需求 | 命令 | 适用场景 |
|---|---|---|
| 查找某个主题的页面 | search | 尚无特定 URL |
| 获取页面内容 | scrape | 已有 URL,页面是静态的或 JS 渲染的 |
| 在网站内查找 URL | map | 需要定位特定的子页面 |
| 批量提取网站部分内容 | crawl | 需要许多页面(例如所有 /docs/) |
| AI 驱动的数据提取 | agent | 需要从复杂网站提取结构化数据 |
| 与页面交互 | scrape + interact | 内容需要点击、填写表单、分页或登录 |
| 将网站下载到文件 | download | 将整个网站保存为本地文件 |
有关详细的命令参考,请运行 firecrawl <command> --help。
抓取与交互:
scrape。它处理静态页面和 JS 渲染的 SPA。scrape + interact。search。避免重复获取:
search --scrape 已经获取了完整的页面内容。不要重新抓取这些 URL。.firecrawl/ 中是否已存在数据。除非用户指定在上下文中返回,否则使用 -o 将结果写入 .firecrawl/。将 .firecrawl/ 添加到 .gitignore。始终引用 URL - shell 会将 ? 和 & 解释为特殊字符。
firecrawl search "react hooks" -o .firecrawl/search-react-hooks.json --json
firecrawl scrape "<url>" -o .firecrawl/page.md
命名约定:
.firecrawl/search-{query}.json
.firecrawl/search-{query}-scraped.json
.firecrawl/{site}-{path}.md
切勿一次性读取整个输出文件。使用 grep、head 或增量读取:
wc -l .firecrawl/file.md && head -50 .firecrawl/file.md
grep -n "keyword" .firecrawl/file.md
单一格式输出原始内容。多种格式(例如 --format markdown,links)输出 JSON。
在处理基于文件的输出(-o 标志)以完成复杂任务时,这些模式非常有用:
# 从搜索结果中提取 URL
jq -r '.data.web[].url' .firecrawl/search.json
# 获取标题和 URL
jq -r '.data.web[] | "\(.title): \(.url)"' .firecrawl/search.json
并行运行独立操作。使用 firecrawl --status 检查并发限制:
firecrawl scrape "<url-1>" -o .firecrawl/1.md &
firecrawl scrape "<url-2>" -o .firecrawl/2.md &
firecrawl scrape "<url-3>" -o .firecrawl/3.md &
wait
对于交互操作,可以抓取多个页面,并使用各自的抓取 ID 独立地与每个页面进行交互。
firecrawl credit-usage
firecrawl credit-usage --json --pretty -o .firecrawl/credits.json
每周安装量
18.6K
代码仓库
GitHub Stars
213
首次出现
2026年1月21日
安全审计
安装于
opencode16.8K
codex16.8K
gemini-cli16.7K
github-copilot16.2K
kimi-cli15.6K
amp15.6K
Web scraping, search, and page interaction CLI. Returns clean markdown optimized for LLM context windows.
Run firecrawl --help or firecrawl <command> --help for full option details.
Must be installed and authenticated. Check with firecrawl --status.
🔥 firecrawl cli v1.8.0
● Authenticated via FIRECRAWL_API_KEY
Concurrency: 0/100 jobs (parallel scrape limit)
Credits: 500,000 remaining
If not ready, see rules/install.md. For output handling guidelines, see rules/security.md.
firecrawl search "query" --scrape --limit 3
Follow this escalation pattern:
map --search to find the right URL, then scrape it.| Need | Command | When |
|---|---|---|
| Find pages on a topic | search | No specific URL yet |
| Get a page's content | scrape | Have a URL, page is static or JS-rendered |
| Find URLs within a site | map | Need to locate a specific subpage |
| Bulk extract a site section | crawl | Need many pages (e.g., all /docs/) |
| AI-powered data extraction | agent |
For detailed command reference, run firecrawl <command> --help.
Scrape vs interact:
scrape first. It handles static pages and JS-rendered SPAs.scrape + interact when you need to interact with a page, such as clicking buttons, filling out forms, navigating through a complex site, infinite scroll, or when scrape fails to grab all the content you need.search instead.Avoid redundant fetches:
search --scrape already fetches full page content. Don't re-scrape those URLs..firecrawl/ for existing data before fetching again.Unless the user specifies to return in context, write results to .firecrawl/ with -o. Add .firecrawl/ to .gitignore. Always quote URLs - shell interprets ? and & as special characters.
firecrawl search "react hooks" -o .firecrawl/search-react-hooks.json --json
firecrawl scrape "<url>" -o .firecrawl/page.md
Naming conventions:
.firecrawl/search-{query}.json
.firecrawl/search-{query}-scraped.json
.firecrawl/{site}-{path}.md
Never read entire output files at once. Use grep, head, or incremental reads:
wc -l .firecrawl/file.md && head -50 .firecrawl/file.md
grep -n "keyword" .firecrawl/file.md
Single format outputs raw content. Multiple formats (e.g., --format markdown,links) output JSON.
These patterns are useful when working with file-based output (-o flag) for complex tasks:
# Extract URLs from search
jq -r '.data.web[].url' .firecrawl/search.json
# Get titles and URLs
jq -r '.data.web[] | "\(.title): \(.url)"' .firecrawl/search.json
Run independent operations in parallel. Check firecrawl --status for concurrency limit:
firecrawl scrape "<url-1>" -o .firecrawl/1.md &
firecrawl scrape "<url-2>" -o .firecrawl/2.md &
firecrawl scrape "<url-3>" -o .firecrawl/3.md &
wait
For interact, scrape multiple pages and interact with each independently using their scrape IDs.
firecrawl credit-usage
firecrawl credit-usage --json --pretty -o .firecrawl/credits.json
Weekly Installs
18.6K
Repository
GitHub Stars
213
First Seen
Jan 21, 2026
Security Audits
Gen Agent Trust HubPassSocketPassSnykWarn
Installed on
opencode16.8K
codex16.8K
gemini-cli16.7K
github-copilot16.2K
kimi-cli15.6K
amp15.6K
React 组合模式指南:Vercel 组件架构最佳实践,提升代码可维护性
102,200 周安装
| Need structured data from complex sites |
| Interact with a page | scrape + interact | Content requires clicks, form fills, pagination, or login |
| Download a site to files | download | Save an entire site as local files |