DEV Community

Cover image for ShopNex: an open-source Shopify alternative you run with one command
ArseniyDev
ArseniyDev

Posted on AI-assisted

ShopNex: an open-source Shopify alternative you run with one command

$29 for this app. $49 for that one. $99 for the one that should have been included in the first place.

If you've run a store on a hosted platform, you know the feeling. The plan is fine, then the small stuff adds up. Store owners and developers keep saying the same things: too many apps, fees on top of fees, a platform that changes things when it likes, and a store that's hard to leave.

That's why I'm building ShopNex: an open-source store you run yourself.

curl -fsSLO https://raw.githubusercontent.com/shopnex-ai/shopnex/main/deploy/docker-compose.yml
docker compose up
Enter fullscreen mode Exit fullscreen mode

Open http://localhost:3000, follow the setup wizard, and you have an admin, a storefront and a checkout.

ShopNex admin dashboard

What you get out of the box

  • A real admin. Products, collections, orders, customers, discounts, shipping, taxes and staff, all in the browser. Payments, email, storage and shipping are settings, not config files.
  • Hosted checkout. Shipping rates, payment methods, discount codes and order confirmation. Stripe Checkout is a bundled app, and manual payment methods work too.
  • A themeable storefront. An Astro storefront with Liquid themes that use Shopify-style names. Or skip it and build your own on the typed Storefront API.
  • Your data in your database. It's PostgreSQL on your server. MIT licensed, no monthly plan, no cut of your sales. You pay your host and your payment processor.

Apps that can't break your core

This is the part I care about most. Integrations in ShopNex run outside the store. They talk to it through scoped API tokens and signed webhooks, and nothing third-party is loaded into the core. When something misbehaves, you know where to look.

There's already a CJ Dropshipping app that imports products as drafts, applies your markup, shows real shipping prices at checkout and sends paid orders on to CJ. You can write your own with the @shopnex/app SDK.

For people who build stores for clients

  • One install, many shops. Set TENANCY_MODE=multi and each client's shop resolves from its own domain, with its own members. Going from one shop to many needs no data migration.
  • Headless when you want it:
import { createStorefrontClient } from '@shopnex/storefront-sdk'

const shopnex = createStorefrontClient({
  baseUrl: 'https://your-shop.com',
  publishableKey: 'pk_…',
})

const { nodes } = await shopnex.products.list({ first: 20, sortKey: 'PRICE' })

const cart = await shopnex.cart.create({
  lines: [{ merchandiseId: nodes[0].variants[0].id, quantity: 1 }],
})
location.href = cart.checkoutUrl // hosted checkout
Enter fullscreen mode Exit fullscreen mode
  • Bring a store with you. The admin imports CSVs from Shopify and WooCommerce (products, customers, orders and discounts), and Magento for products and customers.

Try it in two minutes

No install needed to look around: the live demo has a shared login. If you want it on your own server, the self-hosting guide covers Docker Compose, a one-line installer and one-click deploys.

Who it's for, and who it isn't

ShopNex is for you if you want to own your store and your data, you're comfortable running a small server (or have someone who is), and you'd rather extend a store with apps than fork a framework.

It's not for you yet if your store depends on a long list of Shopify apps, you need managed hosting, or you want zero operations. ShopNex is pre-1.0 and releases often, so pin a version in production. The app store is small, and Shopify-style themes need porting rather than dropping in. If you want a framework to build bespoke commerce logic in code, Medusa is a strong choice with a much bigger community.

Help me make it better

ShopNex is young, and it improves fastest when people use it and tell me what's missing.

What would make you switch your store to something you run yourself? Tell me in the comments.

Top comments (0)