← All documentation · Inventory & Purchasing
Cost prices, margins and gross profit
Enter what each product and variant costs you, see live margins in Catalog, track gross profit on the Sales dashboard and in the Profit by Product report, and control who can see costs with the Costs & profit permission.
7 min read · Last updated
A cost price is what one unit costs your business: what you paid the supplier, or what it costs you to make. Enter it on your products and their variants and LogAI shows the margin next to every price. It also records the cost on every sale line, so the Gross profit tile on Home → Sales and the Profit by Product report can tell you what you actually earned. Costs are internal: they never appear on your online store, invoices or receipts, and the Costs & profit permission decides which roles see them on products, purchases and profit figures.
Set cost prices and check your margins
- Simple products: the Cost price field. Open Catalog → Products, then
Addor edit a product. In the Inventory & Pricing section, fill inCost price(optional, in your currency). The hint reads: “What one unit costs you. Only your team sees it.” To change it later without opening the form, open the product's side panel. Under Pricing & Finance, click theCost pricevalue (or “Add what it costs you”) and type the new figure. - Variable products: the Cost column. For a product with options such as size or colour, the variant table under Options & Variants has a
Costcolumn besidePriceandMRP. Enter each variant's own cost. If you leave a variant's cost blank, it uses the product's own cost price when the product has one (the field shows that figure as a faint placeholder). If the product has none, that variant's cost is unknown. - Read the live margin. As you type, a hint under each variant's cost shows the margin, such as
32% margin. It readsBelow costwhen the price is lower than the cost and adds· product costwhen the variant is using the product's cost. Save the product as usual. - Add Cost and Margin columns to the products table. On Catalog → Products, open
Columns(desktop) and tick Cost and Margin. They're hidden by default. Variable products showBy variantin both columns. Open one to see each variant's figures.
How margins are worked out
Margin % is (selling price − cost) ÷ selling price × 100, and the amount per unit is selling price − cost. The colour tells you how healthy it is:
| What you see | When |
|---|---|
| Green | Margin of 15% or more. |
| Amber | Margin between 0% and 15%. You're still above cost, but only just. |
Red, or Below cost | The selling price is lower than the cost, so every unit sold loses money. |
— | No cost price has been entered, so there's no margin to show. LogAI never assumes a cost of zero. |
In the product side panel, a simple product shows its cost with “profit per unit · N%” beside it. On a variable product, each variant card has a margin chip next to its price. When you expand the card, it shows a Cost price tile, marked “Uses the product's cost price” when it falls back to the product, and a Margin tile with the percentage and the amount per unit. Campaign Studio uses the same cost to show what you keep per unit on an offer and warns you before a discount sells below cost.
Catalog margins vs report margins: The margins in Catalog compare the selling price exactly as entered with the cost, so if your prices include tax, the margin does too. Gross profit and the Profit by Product report work on ex-tax sales after discounts, so their margins can be a little lower than the Catalog figure for the same item.
Each sale keeps the cost it had on the day
When something is sold, LogAI copies the item's cost onto that sale line: the variant's own cost if it has one, otherwise the product's. This is the cost snapshot, and it's what profit is calculated from. If you change a cost price later, past sales keep the cost they were sold at, so last month's profit doesn't move. Only sales made after the change use the new cost.
- Store orders take their snapshot when stock is deducted for the order. If the order later moves to a different branch, it takes stock again there and the snapshot is refreshed with the cost at that moment.
- Invoices you raise yourself (invoices and the Point of Sale) take their snapshot when the line is added. Changing a line's quantity recalculates its cost of goods at the same unit cost. Swapping the line to a different product or variant picks up that item's current cost.
- Invoices created from delivered orders copy the order's cost, so the sale isn't costed twice.
- Older sales made before costing was available have no snapshot, so their cost is unknown. If you edit such an invoice line, it picks up today's cost.
When you receive stock from a supplier
When you receive goods against a purchase order, or record a direct receipt, the receive form has an Update cost prices switch: “Make what you paid the item's cost price, so margins stay current.” It's on by default. When it's on, each received line's unit cost becomes that item's cost price. The variant's cost is set when you received a variant, and the product's when you received a simple product. LogAI uses the latest purchase cost. It doesn't average it with what you paid before. Turn the switch off for a one-off purchase that shouldn't change your margins. On a receipt, a unit cost left blank falls back to the purchase order's cost. On a direct receipt, it falls back to the item's current cost price. A line with no cost at all doesn't change anything. Supplier bills don't change cost prices. The switch only appears for people who can see costs, and receipts by anyone else never change a cost price.
The Gross profit tile
On Home → Sales (see business dashboards), people who can see costs get a Gross profit tile ahead of Revenue. It follows the dashboard's date range and comparison like the other tiles. The caption shows the margin, for example 28% margin. When some units in the period were sold without a known cost, it also shows how much was costed, for example 28% margin · 74% costed. Gross profit = ex-tax sales − cost of goods from each line's snapshot. It covers store orders in revenue-bearing statuses plus invoices you raised yourself, with returned goods taken out.
The Profit by Product report
Reporting → Sales → Profit by Product breaks gross profit down by product and variant, best earners first. Its tiles are Gross profit, Net sales, Cost of goods and Margin. It has two charts, Top products by gross profit and Sales vs cost of goods. Like every report, it supports Compare with previous period and Export CSV (see Reports & analytics).
| Column | Meaning |
|---|---|
| Product, Variant | Shown by default. SKU and Category can be added from Columns. |
| Units Sold | Units sold in the period, less returned units. |
| Net Sales | Ex-tax, after discounts, less received returns. |
| Cost of Goods | Sum of the cost snapshots on the lines sold. |
| Gross Profit, Margin % | Net Sales − Cost of Goods, and that as a share of Net Sales. |
| Cost Known % | Share of sold units that had a cost price when they were sold. Below 100% means some sales count toward profit with no cost behind them. |
| Hidden by default | Sales docs, Returned, Units Before Returns, Units With Cost, Avg Unit Cost and Profit Share %. |
Filters offers Period, Order status (defaults to revenue-bearing statuses), Payment method, Channel, Category, Product and a product-name search. Status, payment method and channel narrow the store-order side only. Invoices you raised yourself count when they're pending, approved, partially paid or paid, and are filtered by invoice date, category, product and name. Shipping lines are left out.
Who can see and edit costs
Costs have their own permission. In Workspace → Roles & Permissions, under the Catalog group, the Costs & profit row controls them. View is the flag that matters: a role without it never sees a cost price or margin on products and variants, the Cost and Margin columns, the Gross profit tile, the Profit by Product report, or purchase costs in Purchases. See Manage your team for how roles work.
- To edit a cost price, you need
Viewon Costs & profit plusUpdateon Products. - Saving a product without the permission doesn't erase its cost. A product or variant saved by someone who can't see costs keeps the cost that was already stored.
- Defaults: the Super Admin always has access. When costing arrived, every role that could edit products got
Viewon Costs & profit, and view-only roles didn't. New custom roles start without it, so tick it for anyone who should see costs. - Reporting access: to open Profit by Product, someone needs
Viewon Reports andViewon Costs & profit.
Edge cases worth knowing
| Situation | What happens |
|---|---|
| No cost price entered | Margins show —. Sales still count in Net Sales but add nothing to Cost of Goods, so profit looks higher than it really is. Cost Known % and the costed caption warn you. Add the cost, and future sales are costed. Past sales stay uncosted. |
| You change a cost price | Only future sales use it. Profit already reported for earlier periods stays the same. |
| A variant without its own cost | It uses the product's cost price if one exists, both for margins and for the cost snapshot. |
| Goods returned and put back in stock | Once the return is received, refunded or exchanged, its units, sales and cost all come out of the report. |
| Goods returned but written off | The sale and units come out, but the cost stays in Cost of Goods. You lost the goods, so the cost is real. |
| Cancelled or failed orders | Excluded, along with unpaid checkouts. Cancelled invoices are excluded too. |
| A product deleted after it sold | Its sales stay in the report, under the name it was sold with. |
| Cost price of zero | Treated as a real cost of zero, so the margin shows as 100%. Leave the field blank if you don't know the cost. |
Start with your bestsellers: Profit is only as good as the costs behind it. Sort Profit by Product by Units Sold, add cost prices for the top items first, and watch Cost Known % climb. To keep costs current without retyping them, receive purchases with Update cost prices switched on.
Frequently asked questions
Where do I enter the cost price of a product?
For a simple product, use the Cost price field in the Inventory & Pricing section of the product form, or click the cost in the product's side panel. For a variable product, use the Cost column in the variant table. A variant left blank uses the product's own cost price if it has one.
If I change a cost price, does my past profit change?
No. Each sale line keeps the cost the item had when it was sold, so profit for past periods stays the same. Only sales made after the change use the new cost.
Does LogAI calculate a weighted average cost?
No. When you receive stock with Update cost prices switched on, what you paid becomes the item's cost price, so LogAI tracks the latest purchase cost. Each sale then uses whatever cost price the item had at that moment.
How do I stop staff from seeing cost prices and profit?
In Workspace, Roles & Permissions, untick View on the Costs & profit row (in the Catalog group) for their role. They will no longer see cost prices, margins, the Gross profit tile, the Profit by Product report or purchase costs, and saving a product won't clear the cost that's stored.
Why is Cost Known % below 100?
Some units in the period were sold while the item had no cost price, including sales made before costing was available. Those units count toward net sales but add no cost, so profit is overstated. Add cost prices to fix future sales.
Why does the margin in Catalog differ from the margin in the profit report?
Catalog compares the selling price as entered, which may include tax, with the cost. The profit report uses ex-tax sales after discounts and takes out returns, so its margin is usually a little lower.
Are returns included in gross profit?
Yes. Once a return is received, refunded or exchanged, its units and sales come out. Its cost comes out too if the goods went back into stock. If they were written off, the cost stays in.
Open the LogAI app — start free, no credit card required.