MCP Forge

The MCP Forge Blog

Practical guides on building MCP servers that are secure and lean.

The MCP Server Security Checklist

Auth, SSRF, secrets, validation, rate limiting, and token bloat, in one checklist.

How to add authentication to your MCP server

Shared bearer tokens, HS256 and RS256 JWTs, OAuth, and why you must fail closed.

SSRF in MCP servers: what it is and how to prevent it

How a fetch tool becomes a proxy into your network, and how to build a safe fetch.

How to cut your MCP token usage

Why five servers can cost 50 to 75k tokens per request, and five ways to fix it.

How to deploy a secure MCP server

Docker, Fly, Railway, or a VPS, with the security settings you must not skip.

Claude and Cursor MCP setup: a security-first guide

Add MCP servers without leaking secrets, your filesystem, or your context budget.

How to write a secure MCP tool

Validate inputs, fetch safely, keep side effects explicit, stay token-lean.

What is the Model Context Protocol (MCP)? A developer guide

How MCP clients, servers, tools, and transports fit together, plus the costs to watch.

How to build an MCP server in Python with FastMCP

Build, run, and connect a Python MCP server with FastMCP, security baked in.

MCP transports: stdio vs streamable HTTP (and why to drop SSE)

Choosing between stdio and streamable HTTP, plus why deprecated SSE has to go.

Input validation for MCP tools: bounded schemas that fail closed

Validate every MCP tool input with a bounded typed schema and fail closed.

How to handle secrets in MCP servers safely

Keep API keys out of config, URLs, and logs in your MCP server.

Prompt injection in MCP servers: risks and real defenses

How tool descriptions and fetched content carry injection, and how to defend against it.

How to rate limit an MCP server

Per-client token buckets and where to enforce them in an MCP server.

How to monitor and log an MCP server

What to log, what to redact, structured JSON logs, and the first alerts worth setting up.

How to debug an MCP server: common errors and fixes

Fix MCP handshake, tool-not-found, transport, and env errors with the Inspector and logs.

6 common MCP server mistakes and how to fix them

No auth, cleartext HTTP, broad roots, unpinned runners, too many tools, leaked secrets.