-
Notifications
You must be signed in to change notification settings - Fork 24
Description
Problem
When using a self-hosted Firecrawl instance with --api-url, the configuration is not persisted. On the first command, --api-url http://localhost:3002 scrape https://example.com works correctly and skips authentication. However, on the second command, running just firecrawl scrape https://example.com defaults back to https://api.firecrawl.dev and triggers an authentication prompt, even though the user already configured a custom API URL.
This forces users to pass --api-url on every single command, defeating the purpose of configuration persistence for self-hosted setups.
Steps to Reproduce
- Start a local Firecrawl instance:
docker run -p 3002:3002 firecrawl-local - Run first command:
firecrawl --api-url http://localhost:3002 scrape https://example.com- Result: ✅ Works, no authentication required
- Run second command:
firecrawl scrape https://example.com- Expected: ✅ Uses the previously configured
http://localhost:3002, no auth prompt - Actual: ❌ Defaults to
https://api.firecrawl.dev, prompts for authentication
- Expected: ✅ Uses the previously configured
Why This Matters
- Self-hosted deployments are common in enterprise environments where users should not need cloud API credentials
- The README explicitly documents that "authentication is automatically skipped" for custom API URLs, implying the URL should be saved
- Users developing locally or running internal Firecrawl instances have no way to set a persistent default without wrapping the CLI in shell aliases or environment variables
- This degrades the developer experience compared to the cloud-first workflow
Expected Behavior
firecrawl config --api-url http://localhost:3002 (or similar persistent config command) should:
- Save the API URL to the config file (likely
~/.firecrawl/config.jsonor similar) - On subsequent commands without
--api-url, use the saved URL instead of the cloud default - Allow users to reset with
firecrawl config --api-url https://api.firecrawl.devorfirecrawl config --reset
Related
This appears related to #53, which mentions config persistence issues with self-hosted setups.
Contributed by Klement Gunndu