How does a finished goods item valuation rate calculating in erpnext

Hi Team,

How does a finished goods item valuation rate calculating in ERPNEXT, can we change it with a standard price?

Please guide me in this, any information will be much appreciated.

Regards,
Shivansh

Hi Shivansh,

In ERPNext, the Finished Goods valuation rate is calculated during the Stock Entry (Manufacture/Repack) process and is usually based on the Valuation Rate of raw materials + Additional Costs.

Here’s the default logic:


1. How ERPNext calculates Finished Goods valuation rate

  • When you manufacture an item via Work Order → Stock Entry (Manufacture):
    • It takes the valuation rate of each raw material from stock ledger.
    • Adds additional costs (if you entered them in Stock Entry → Additional Costs section).
    • Divides the total cost by the quantity of Finished Goods produced.
  • Formula (simplified):

pgsql

Valuation Rate = (Total RM cost + Additional Costs) / Finished Goods Qty
  • The valuation rate comes from:
    • Weighted Average, FIFO, or Moving Average method (set in Stock Settings).
    • Raw material cost is pulled from latest stock ledger entries.

2. Changing valuation to use Standard Price

If you want the Finished Goods valuation rate to always use a fixed “Standard Price” instead of being calculated from raw materials:

  1. Set the Valuation Method for that item to Standard Rate:
  • Go to Item → open your Finished Goods item.
  • Set Valuation Method to Standard Rate.
  1. Enter Standard Rate:
  • In the Item master, fill in Standard Rate field.
  1. ERPNext will now use this standard rate instead of calculating from actual raw material costs.

3. Alternative approaches

  • Custom script: You can override the valuation rate during Stock Entry submission by setting:

python

fg_item.valuation_rate = 500  # Your custom price

in a Stock Entry custom before_submit hook.

  • Pricing Rule approach: This affects selling prices but not valuation rate (so only useful if you want to influence invoices, not stock ledger).

Caution:
If you override valuation with a standard price, your stock valuation in accounts will no longer reflect actual RM costs, which may affect gross margins.

1 Like