Fetch MCP server guide
Overview
A simple, lightweight MCP server that retrieves data from a website to add real-time context to an AI agent workflow.
GoFetch is a Go implementation of the original Fetch MCP server with improved performance and security, built by Stacklok.
Metadata
Error details
# Error fetching data for fetch
# Failed to fetch MCP server data. See logs for details.
# Please check that the server exists in the registry and thv command is available
Usage
- UI
- CLI
- Kubernetes
Select the fetch
MCP server in the ToolHive registry. No additional
configuration is required to run it.
By default, it can access any website. To restrict its network access, enable network isolation and enter the allowed hosts and ports.
Run with the default configuration:
thv run fetch
To control which website resources the server can access, create a custom permission profile:
{
"network": {
"outbound": {
"insecure_allow_all": false,
"allow_host": [
"host.docker.internal",
"intranet.example.com",
".googleapis.com"
],
"allow_port": [443]
}
}
}
Then run the server with the profile and enable network isolation:
thv run --isolate-network --permission-profile fetch-profile.json fetch
Create a Kubernetes manifest to deploy the Fetch MCP server:
apiVersion: toolhive.stacklok.dev/v1alpha1
kind: MCPServer
metadata:
name: fetch
namespace: toolhive-system
spec:
image: ghcr.io/stackloklabs/gofetch/server:0.0.5
transport: streamable-http
targetPort: 8080
port: 8080
permissionProfile:
type: builtin
name: network
Apply the manifest to your Kubernetes cluster:
kubectl apply -f fetch.yaml
Sample prompts
Here are some sample prompts you can use to interact with the Fetch MCP server:
- "Fetch the latest news from
https://news.ycombinator.com
" - "Get the current weather for
https://weather.com
" - "Retrieve the latest blog posts from
https://example.com/blog
"
Recommended practices
- Use network isolation to restrict the server's outbound network access to the specific hosts and ports required for your use case.
- Enable telemetry to monitor tool usage including URL access for security and auditing purposes.