Using Headless WordPress with SvelteKit for the first time

I decided to try headless WordPress with SvelteKit for the first. I was using HyGraph as my headless CMS solution.

Using Headless WordPress with SvelteKit for the first time
Photo by Markus Winkler / Unsplash

I thought I was done with WordPress. Back in March 2022, I thought I would never touch WordPress again after I started using GraphCMS (now HyGraph) as the headless content management system (CMS) for the SvelteKit project I was working on.

I stand corrected!!!

What changed my mind? Simple, since WordPress is still one of the most popular CMSs around with over 800 million installations, the odds of finding an average user that knows how to use WP is quite good. One of my clients did not feel comfortable using HyGraph. He asked me if I could do his site in WordPress.

I refused, stating that I really did not have the time to maintain a full stack LEMP server just for WordPress. If you ever managed a server running WordPress, I think you will understand. PHP version updates always break something. Plugin updates always mess up the cached content. This is one main reason managed WordPress hosting can cost an arm and leg.

With headless WordPress, I found an easier solution that did not require me to maintain my server. Namecheap. Yes, I used a shared hosting solution to maintain my headless WordPress installations.

In my next update, I will discuss how I set up WordPress as my headless CMS, including the plugins I am using. My current demo site is hosted at Vercel with all my images hosted at Cloudinary. I am using REST API to fetch all the contents. Eventually, I will switch to GraphQL. I am just waiting for SvelteKit to hit a stable release.

Well, back to work. Lets see how this goes.

Subscribe to Kevin Matsunaga

Don’t miss out on the latest issues. Sign up now to get access to the library of members-only issues.
jamie@example.com
Subscribe