Hello, world
by Jane Doe · Dec 8, 2025
WPGraphQL is a free, open-source WordPress plugin that provides an extendable GraphQL schema and API for any WordPress site.
query GetPosts { posts { nodes { title date } } }
{ "data": { "posts": { "nodes": [ { "title": "Hello, world", "date": "2025-12-08" } ] } } }
Framework Agnostic
WPGraphQL separates your CMS from your presentation layer. Content creators use the CMS they know; developers use the frameworks and tools they love.
Gatsby
Next.js
Vue
SvelteEfficient Data Fetching
With GraphQL, the client makes declarative queries, asking for the exact data needed, and exactly what was asked for is given in response — nothing more. Clients have control over their application, and the GraphQL server only fetches what was requested.
query GetUser { user(id: "dXNlcjox") { name email } }
{ "data": { "user": { "name": "Jane Doe", "email": "[email protected]" } } }
Nested Resources
GraphQL queries access multiple root resources and smoothly follow references between connected ones. While a typical REST API would require round-trip requests to many endpoints, GraphQL can return everything your app needs in one round-trip — quick even on slow mobile connections.
query GetPostsWithAuthor { posts { nodes { title author { node { name } } categories { nodes { name } } } } }
{ "data": { "posts": { "nodes": [ { "title": "Hello, world", "author": { "node": { "name": "Jane" } }, "categories": { "nodes": [ { "name": "News" } ] } } ] } } }
Data Colocation
GraphQL fragments let each component declare the fields it needs. Compose those fragments into one query at the page level — the data graph stays in sync with the UI tree, automatically.
by Jane Doe · Dec 8, 2025
by Alex Chen · Dec 4, 2025
by Sam Patel · Nov 27, 2025
Hover a card to see its component name
// pages/index.tsx query GetRecentPosts { posts { nodes { ...PostCard } } } // components/PostCard.tsx fragment PostCard on Post { id title date author { node { name } } }
Trusted by
Digital agencies, product teams and freelancers around the world trust WPGraphQL in production to bridge modern front-end stacks with content managed in WordPress.








Get Started
Free, open-source, and trusted by teams shipping WordPress at scale.