1. Quick comparison
At a glance: MCP is the agent-native protocol; REST and GraphQL are general-purpose APIs you already know; custom integrations are the escape hatch when nothing standard fits.
| Aspect | Recommended MCP | REST API | GraphQL | Custom |
|---|---|---|---|---|
| Purpose | AI-native protocol layer | General HTTP resource API | Flexible query API | One-off bespoke glue |
| Architecture | Client ↔ MCP server ↔ WordPress | App ↔ REST routes ↔ WordPress | Client ↔ GraphQL ↔ WP | Custom scripts / plugins |
| Data fetching | Tools + resources + prompts | Fixed endpoints per resource | Client shapes the query | Whatever you code |
| AI-native | Built for agents | Adapted via prompts | Adapted via schema | Fully manual |
| Schema / typing | Capability negotiation | OpenAPI / ad hoc | Strong schema | None unless you add it |
| Auth model | Per-client + scoped tools | App passwords / OAuth | Token + field rules | Varies wildly |
| Best for | Agent workflows | CRUD integrations | Flexible UIs | Legacy one-offs |
2. Architecture overview
Each stack shows who talks to whom. MCP inserts a dedicated server between the agent and WordPress; REST and GraphQL expose WordPress data through HTTP; custom code skips the shared contract entirely.
AI Agent
Claude, Cursor, ChatGPT
MCP Protocol
JSON-RPC transport
WordPress
Posts, users, settings
App / Client
Mobile, SaaS, script
REST Endpoints
/wp-json/wp/v2/...
WordPress
Core data layer
Client App
React, mobile, agent
GraphQL Layer
Single endpoint
WordPress
Resolvers → data
Integrator
Your team / agency
Custom Code
PHP, cron, webhooks
WordPress
Direct DB / hooks
3. How requests & responses work
The request lifecycle differs more than the transport name suggests. MCP emphasizes capability discovery and typed tool calls; REST emphasizes resource URLs; GraphQL emphasizes shaped queries.
Client opens session and negotiates capabilities.
Agent discovers tools, resources, and prompts.
Model picks a tool with structured arguments.
Server executes on WordPress and returns typed JSON.
Stateful, context-rich, AI-first
Client builds HTTP request to a known route.
WordPress authenticates and routes to controller.
Core returns JSON for posts, users, or meta.
Client parses response and continues workflow.
Stateless, resource-oriented, mature
Client sends one query with selected fields.
GraphQL validates against schema.
Resolvers fetch only requested data.
Nested response returned in one round trip.
Flexible queries, fewer round trips
Developer writes integration logic by hand.
Calls WP functions, SQL, or remote APIs.
Formats output for the consumer.
Every new client may need new code.
Maximum control, least reuse
4. When to use what?
Most WordPress products will run REST (or GraphQL) for humans and apps, and add MCP when AI agents need the same backend with a discoverable, auditable tool surface.
AI agents that need tools + context
Multi-client support (Claude, Cursor, ChatGPT)
Typed, discoverable capabilities
Long-running agent workflows
Mobile apps and headless frontends
CRUD on posts, users, media
Well-documented public APIs
Integrations that predate agents
Complex UIs with nested data
Minimizing over-fetching
Apps that own the query shape
Teams already on WPGraphQL
Legacy one-off automations
Highly specialized business rules
When no standard API fits
Short-lived internal scripts