Set up Shopify ​

The Shopify connector pulls orders from Shopify and creates Sales Orders in ERPNext. If the customer or the item of an order is not in ERPNext, the connector creates it from the Shopify data. It can also push stock levels and new items to Shopify.

INFO

The Shopify connector is part of the ecommerce_integrations app. The old Shopify integration inside ERPNext was removed in version 14.

Install the app ​

  • Frappe Cloud: install Ecommerce Integrations from the Frappe Cloud Marketplace in your site dashboard.
  • Hosted by Frappe: raise a support ticket to get the app installed.
  • Self-hosted: run bench get-app ecommerce_integrations --branch main, then bench --site <your-site> install-app ecommerce_integrations. The source code is on GitHub.

WARNING

If you used the old Shopify integration inside ERPNext, disable it before you set up the new one. The app migrates existing data, such as the Shopify product ID of each item. Check the migration status in the Ecommerce Integration Log list.

Create a custom app in Shopify ​

  1. In the Shopify admin, open Apps, and select Develop apps for your store.
  2. Create an app.
  3. Give the app these Admin API access scopes:
    • Draft orders: read and write
    • Orders: read and write
    • Locations: read
    • Customers: read
    • Assigned fulfillment orders: read and write
    • Products: read and write
    • Product listings: read and write
    • Inventory: read and write
  4. Install the app on your store.
  5. Copy the Admin API access token and the API secret key.

Connect Shopify in ERPNext ​

  1. Open Shopify Setting.
  2. Enter the Shopify store URL, the access token, and the API secret.
  3. Set the customer, company, and inventory defaults, for example the customer group, the company, the price list, and the warehouse.
  4. Set the order sync options. You can create the Sales Invoice and the Delivery Note in ERPNext when Shopify captures the payment or fulfills the order.
  5. In the tax mapping table, map each Shopify tax and shipping charge to an ERPNext account. Find the tax names in the Shopify admin.
  6. Turn on the Shopify sync, and save. ERPNext registers its webhooks in Shopify and starts to sync orders.

Shopify Setting with the order sync options

Sync old orders ​

The connector syncs new orders after you enable it. To import earlier orders:

  1. Select Sync Old Shopify Orders.
  2. Enter the from date and the to date.
  3. Save. The import runs in the background and can take a few hours.

Sync inventory to Shopify ​

ERPNext pushes the stock level of synced items to Shopify. Each ERPNext warehouse maps to one Shopify location.

  1. Select the inventory sync checkbox. A warehouse mapping table appears.
  2. Select the sync frequency. 30 to 60 minutes is a good value.
  3. Select Fetch Shopify Locations to fill the table with your Shopify locations.
  4. Link each location to an ERPNext warehouse, and save.

WARNING

ERPNext is the source of truth for stock. When the stock in ERPNext changes, the connector overwrites the stock level in Shopify. Shopify does not support fractional quantities, so ERPNext rounds them down.

Upload items to Shopify ​

Select Upload new ERPNext items to Shopify to create each new ERPNext item in Shopify. You can also update the Shopify product when you update the item. The connector maps these fields:

ERPNext fieldShopify field
Item NameTitle
Item CodeSKU
DescriptionDescription
Item GroupProduct type
Weight per UnitWeight
Weight UOMWeight unit

New products are drafts in Shopify and are not published. Add more details in Shopify later. Item upload does not work for data import or for item variants and templates.

How cancelled orders sync ​

  • If the Shopify order is cancelled and the Sales Order has no invoice or delivery note, ERPNext cancels the Sales Order.
  • If the Sales Order has linked documents, ERPNext adds the Shopify status to them. You cancel or return the documents yourself.