Guide
Set Shopify products out of stock by a feed field and value
Last updated: November 23, 2026
A feed can report 10 units while a separate stock flag says the item is unavailable. On Pro or Scale, Simple CSV can use that flag to set inventory to 0, even when the quantity is positive.
Before you start
This Advanced inventory rule works for new-product imports and updates on Pro and Scale, including trials. Paid legacy plans also have access. Free does not include this rule.
Open Simple CSV from Shopify Admin. Start your import or update with your file or feed URL. If Quick setup opens for a new-product import or a recognized updates-only feed, you can complete it. Then open the feed and click the inventory icon under Actions to open Advanced inventory. It looks like a warehouse and is the second icon from the left.

To use the normal import steps instead, choose Set it up myself in Quick setup.
Choose the Shopify location this import will update. Inventory replaces the Available quantity at that one location. Available is the stock Shopify can sell.
1. Keep the quantity mapped to Inventory
If you used Quick setup, the stock quantity is already mapped to Inventory. Keep that mapping and continue to step 2.
If you are using the normal setup steps, follow the mapping instructions below.
On Mapping, map the column that contains the stock quantity to Inventory. This column should contain a number, for example 10. Its name depends on your feed.
Do not map the column that describes availability to Inventory. If it is mapped there, remove that mapping. You will select this column in the rule instead. Use the column names from your own feed. The names in the screenshots below are examples.
For an update, match variants by SKU, first barcode or Shopify Variant GID. A Variant GID is Shopify’s ID for one variant. Handle and Product GID matching cannot update variant inventory.
2. Select the field in Advanced inventory
Open Advanced inventory and find Set out of stock by value. These controls appear when inventory is mapped.

Open Field and choose the source column that describes availability. The example below uses 1=In Stock|0=OOS. Your feed may use a different name.

3. Enter the value that means out of stock
In Value, enter the value your feed uses for an unavailable item. In this first example, that value is 0. A matching row gets inventory 0, even if its quantity column says 10.

Another feed may use a field named availability with the value RED for unavailable items. In that case, select availability and enter RED. Check what the values mean in your own feed before setting the rule.

4. Check the result
Continue to Preview and check your setup. On Summary, choose Full file dry run to check the whole file without changing Shopify. Read how a dry run differs from a limited live run.
For the first example, with Value set to 0 and no other inventory rules, the same mapped quantity produces these results:
| Stock flag | Mapped quantity | Available after the run |
|---|---|---|
| 0 | 10 | 0 |
| 1 | 10 | 10 |
After a live run, check each variant’s Available quantity at the selected location in Shopify. Stock at another location and the Shopify setting Continue selling when out of stock can still allow orders.
Matching details and other inventory settings
The field value must match exactly, but letter case is ignored. For example, inactive matches INACTIVE, but does not match inactive soon.
Spaces in the source cell are kept. A source value with spaces around it may not match. Spaces around the saved Value are removed. An empty Value can match an empty source cell.
Advanced inventory has a separate option to set a fixed stock quantity. On updates, entering a quantity in that option makes it take priority over the field/value rule, including when the configured quantity is 0. Leave that option blank to use this rule.
This rule checks a value in a row that is present in the feed. It does not handle products missing from the feed. For missing products or variants, use optional out-of-feed cleanup, available on Scale only. Cleanup is disabled while Choose products conditions are set.