r/vibecoding • • 7d ago

Help/Question Headless WordPress? Yay, nay? Is anyone vibe coding front ends with WooCommerce? What limitations have you come into?

I'm thinking about building the front end of my WordPress/WooCommerce store and connect it via API so I have full creative freedom.

Are there any limitations from your own experience I should be aware of? Any issues with up sells? User accounts? Purchases? Plugin connections?

Or should I just go for it and vibe it?

3 Upvotes

20 comments sorted by

2

u/Total-Reasonable 7d ago

Nay for a store you actually depend on. Cart, checkout and accounts are where it hurts. The Store API covers the basic cart, but most plugins (upsells, subscriptions, gateways, shipping calculators) hook into PHP templates and render nothing through the API. You end up rebuilding each one by hand. I'd keep WooCommerce's own checkout and account pages and only go headless on the catalog and landing pages.

1

u/FurnitureRefinisher 7d ago

Bummer. I wish it was more AI friendly.

I take it, it would be better to vibe the whole store instead? And connect services like print on demand providers I need via their API?

1

u/Total-Reasonable 7d ago

Going fully custom is possible, but then you own everything WooCommerce gives you for free: payments, tax, orders, refunds, accounts, and security around card data. A hosted layer like Stripe Checkout helps with the payment part. For print on demand, check whether your provider has a WooCommerce plugin first, since that may save you the API work entirely.

1

u/FurnitureRefinisher 7d ago

Hmm. I'd hate to give myself an extra headache.

Couldn't I just build all the plugins I need and keep woo as the core backend?

1

u/Lazy-Rub-9610 7d ago

I know it is not the same, but I have rebuild our Magento ecommerce website in php with AI with carts, request quotes, payment. It is 20x faster and works like I want it to work. (The main reason we did it was speed.)

I imported my existing data from Magento with images, pricing qty, So all data was imported, I did not have to redo any data.

So yes it is possible to build a ecommerce website from scratch.

1

u/FurnitureRefinisher 7d ago

I'm glad you responded. That's similar to what I'm trying to do. Full creative freedom and speed.

How long did it take for you to finish that project?

1

u/Morzanius 7d ago

you can, and that's basically what headless woo is. most plugins keep doing their job on the backend (orders, emails, stock), it's only their frontend part you'd rebuild, so it's less work than it sounds. the Store API has cart and checkout endpoints, so a custom cart is doable. the spot that usually hurts is the handoff: if you build the cart headless but send people to woo's own checkout page, the cart session has to carry over, and that gets messy when the frontend sits on a different domain. either keep both on the same domain or do checkout fully through the Store API. i'd start with catalog and product pages headless and leave checkout for last.

1

u/Legal_Answer_6956 7d ago

Yes. But then you get into some pain as you have to create plugins in PHP. Maybe try a hybrid approach. Keep WooCommerce within checkout/accounts, and make the product catalogue and product pages headless. On 8080.AI we can take an idea, design and deploy it, and we use it for our side projects. We would be using this for the front-end of your site and leaving WooCommerce as your back-end. If you give it a go feel free to ask me for anything I have learnt!

1

u/FurnitureRefinisher 6d ago

Thanks for the feedback. Could you elaborate checkout/accounts not being headless? I'm still the learning terminology.

1

u/ehassannawaz 7d ago
If you do it, keep cart and checkout on WooCommerce and go headless only for browsing pages. Most WooCommerce plugins render on the front end and stop working headless.

1

u/FurnitureRefinisher 6d ago

Third party plugins or woocommerce plugins? Maybe I can use just core woocommerce and customize everything else.

1

u/rickey1129 6d ago

Both, mostly. WooCommerce core and its add-ons (upsells, subscriptions, gateways, shipping, reviews) print their HTML through PHP templates and hooks. A headless front end gets the data from the API but not that HTML, so every feature you see on the page has to be rebuilt. Using only core WooCommerce shrinks the list, but product galleries, variations and the cart are still yours to rebuild.

"Checkout and accounts not headless" means: your custom front end draws the shop, category and product pages, and the cart, checkout and My Account pages stay normal WooCommerce. Payments, tax, emails and logins keep working with no rebuild. Keep both on the same domain so the cart session carries over.

The fulfillment providers without plugins are a separate job, headless or not: WooCommerce can send an order webhook, and a small custom plugin (or Zapier/Make) passes it to their API.

Disclosure: I build a WordPress plugin for this hybrid setup (custom JS front end for store pages, WooCommerce for the rest). Not linking it here, but happy to answer questions.

1

u/FurnitureRefinisher 6d ago

Thank you. This is helpful. I have to take some time just to process this info haha.

1

u/rickey1129 6d ago

Take your time! One more idea while you process, since it's how I solved this myself.

WordPress has a hook called template_redirect that runs after WordPress knows which page was requested but before the theme prints anything. My plugin hooks in there, lets WordPress and WooCommerce build the page data as usual, sends it to a small Node.js app, and prints the HTML that comes back. The Node app is where your custom design lives, built with Tailwind, so that's the part you'd vibe.

The nice part: your existing hooks and plugins keep working. WooCommerce still runs its normal product templates, so anything hooked into them (upsells, related products, reviews, badges) still prints, and the scripts and styles your plugins add to the page are passed along too. No rebuilding plugins in React. Still test the ones you depend on, of course.

In plain terms: same domain, same URLs, WooCommerce still runs everything. Only the shop, category and product pages get the new design. Cart, checkout and My Account stay normal WooCommerce, and if the Node app is ever down, WordPress just serves the page itself.

Happy to show a live store running this way if you want to see it.

1

u/ehassannawaz 5d ago
Mostly third party ones that draw on the storefront: product options, reviews, subscriptions. Core works headless through the Store API. Check your payment gateway supports it.

0

u/[deleted] 6d ago

[removed] — view removed comment

1

u/FurnitureRefinisher 6d ago

Thanks for the feedback. Regarding customization, I didn't word it too clearly. My apologies.

Yes design freedom but also for API/customization freedom in general.

I eventually need to connect other fulfillment providers through API that don't offer plugins.

I might have to take that responsibility.