Today I learned

Headless Wordpress

Edit this Post Opens in new tab

Today I learned about headless wordpress. Wordpress now offers a REST API which makes it possible to decouple the frontend completely from the wordpress backend.

This is pretty cool, because I'm faster and more comfortable with JavaScript when developing the frontend compared to the wordpress way where you mix you're HTML with PHP.

For example: This makes it possible for me to use GatsbyJS for the frontend and consume the content from wordpress through the API. Gatsby offers a plugin to do all the heavy lifting for me and enables the bridge between wordpress and Gatsby: gatsby-source-wordpress Opens in new tab

Of course this brings some pros and cons with it. I researched a bit and collected a few articles which go into detail about using wordpress as a headless CMS.

From the gatsby documentation: What is Headless WordPress? Opens in new tab

From Chris Coyier on Just How Niche is Headless WordPress? Opens in new tab

I hope you enjoyed this post and learned something new. If you have any questions, feel free to reach out to me on Twitter Opens in new tab or via Email Opens in new tab.

If you want to support me, you can buy me a coffee. I would be very happy about it!

☕️ Buy me a coffee ☕️

I wish you a wonderful day! Marco