Tracking Usage of Your MCP Server with Scarf
Scarf Gateway provides a very simple redirect layer to track requests through arbitrary URL templates. Follow these instructions to track downloads and requests to your MCP Server.
Scarf Gateway provides a very simple redirect layer to track requests through arbitrary URL templates. Follow these instructions to track downloads and requests to your MCP Server.
Step-by-Step Instructions
1. Create a File Package on Scarf
- Navigate to your Scarf dashboard (https://app.scarf.sh).
- Select “Add Package” → Choose “File Package”.
- Enter a descriptive name, e.g. “My MCP Server”
- Select “Use catch-all redirect for target domain”. This will ensure all endpoints are supported, as well as any new capabilities are added in the future. Scarf will redirect all of your traffic seamlessly.
- Enter the domain where your MCP server is hosted.
1a. Set up a dedicated custom domain (recommended)
To serve traffic via your own domain rather than a Scarf provided domain(optional but recommended):
- Create a CNAME record in your DNS provider pointing your domain (e.g., mcp.example.com) to the domain provided by Scarf (gateway.scarf.sh).
- Follow the instructions to verify your domain via TXT record.
2. Verify and Test
Once your DNS resolves, your tracked MCP server endpoint will be ready! Try it out through whatever tools you’re using, e.g. accessing your server from Cursor. Confirm the response matches the expected output from your original MCP server.
3. Access Analytics and Data
Your Scarf dashboard now tracks usage analytics, giving you:
- Number of requests
- Unique users
- Geo-location insights
- Which companies are engaging
This setup allows you full visibility into MCP server usage, with absolutely no code and transparently routing traffic with minimal overhead.
Getting the Most Out of Your Company Unlock Credits
Company unlocks are most useful when you filter, size, sort, and schedule them around the organizations you actually care about.
What 3,600+ Maven Central publishers do after claiming their namespace on Scarf
Scarf has now onboarded 3,693 open source organizations from Maven Central as part of our partnership with Sonatype. We now have a meaningful signal on how these teams are leveraging Scarf most effectively.
Introducing Dependency Radar
Dependency Radar is a real-time supply chain security feed built from open source download activity tracked by Scarf.