Installation & Getting Started
If you've had previous experience with Gatsby or you like to move fast, you can use the quick start steps below to get up and running quickly. If you'd like to take a step back and learn more first, head over to our tutorials
Install a starter
gatsby new my-wordpress-gatsby-site https://github.com/gatsbyjs/gatsby-starter-wordpress-blog
Install and activate both of the following plugins in a live WordPress instance.
gatsby-config.jsof the starter you just set up, update the plugin options for
gatsby-source-wordpress. Change the
urloption so that it points to your WordPress instance GraphQL url. This should be the full url of your GraphQL endpoint. E.g.
gatsby developand experience the magic
Create your beautiful and accessible app
Build with Gatsby Cloud & deploy to Netlify for a fast, wonderful, and affordable CI/CD experience
For a fast, easy, and reliable WordPress local dev server, use Local by Flywheel. This will save you time setting up WordPress on your computer and you can easily push and pull to and from Flywheel/WPEngine hosting!
Required WordPress Dependencies
In addition to WordPress, there are 2 other required plugins on the PHP side of things. If you're on the latest version of the source plugin and these plugins, everything will work great. If there is a version mismatch, you'll be notified and provided a download link for the correct versions in your terminal via our compatibility API when you run a build
This plugin turns your WordPress instance into a GraphQL server.
This plugin modifies the WPGraphQL schema in Gatsby-specific ways and also keeps a record of when user actions happened. This allows us to do selective cache invalidation in Gatsby (to speed up builds) and add Preview support.
Please note that we only officially support the latest version of WordPress. However, WordPress is great at keeping backwards compatibility and older versions may work.