Manufacturing in ERPNext
ERPNext offers a flexible manufacturing system that can handle various manufacturing approaches, from discrete assembly to process manufacturing. At its core is the relationship between Bills of Materials (BOMs) which serve as "recipes" and Work Orders which are "executions of recipes". This article will demonstrate the accounting impacts through a bakery example, showing how ERPNext handles the manufacturing of a simple product.
Core Manufacturing Documents
Each manufacturing document has specific responsibilities in managing the flow of materials, labor, and costs:
Bill of Materials (BOM) serves as the master recipe for manufacturing. It defines the required materials and their quantities, specifies which operations occur at which workstations, and sets expectations for output quantities. While it contains rates, these are used for planning rather than actual cost application. The BOM is versioned, allowing process improvements to be tracked over time while maintaining historical records.
Production Plan optionally aggregates demand from Sales Orders and Material Requests. It helps optimize manufacturing by combining similar items, planning material requirements, and managing capacity across workstations. While useful for larger operations, many businesses start manufacturing directly from Work Orders.
Work Order executes a specific BOM for a required quantity. It scales the material requirements from the BOM and coordinates the timing of operations. The Work Order is the source document for subsequent stock entries and job cards, but makes no stock or accounting entries itself.
Job Card tracks the actual time spent at each workstation operation. While it creates no accounting entries, the hours it records are multiplied by workstation rates to determine labor and overhead costs in the final Manufacture Entry.
Stock Entry handles all inventory movements and cost applications:
- Material Transfer moves raw materials to Work in Progress
- Manufacture Entry moves materials from WIP to finished goods, adds labor/overhead costs from Job Cards based on workstation rates, and handles any scrap quantities
Workstation defines the rates for labor and overhead that will be applied based on Job Card hours. It can also track capacity and maintenance schedules, though these are optional for basic manufacturing.
An Example
A local bakery produces sourdough bread loaves. A BOM that describes a recipe for single loaf may look like:
- 10kg flour
- 7kg water
- 200g salt
- 2kg active starter
- 30 minutes of labor at the mixing station
- 45 minutes of labor at the baking station
When the bakery produces a batch of 20 loaves:
| Item | Quantity | Unit Cost | Total |
|---|---|---|---|
| Flour | 10kg | $1.00 | $10.00 |
| Water | 7kg | $0.03 | $0.21 |
| Salt | 200g | $2.00 | $0.40 |
| Starter | 2kg | $1.00 | $2.00 |
| Mixing Labor | 30 min | $15.20 | $7.60 |
| Baking Labor | 45 min | $15.20 | $11.40 |
| Total Cost | $31.61 |
This leads to a projected per-unit cost of $1.58.
Manufacturing Stock Entry Accounting
When our bakery begins production of a 20-loaf batch, they first move raw materials to the production area. ERPNext records this movement with a Material Transfer Stock Entry, which moves the value of materials from Raw Materials inventory to Work in Progress:
| Account | Warehouse | Item | Stock Ledger | Debit | Credit |
|---|---|---|---|---|---|
| Work in Progress | Work In Progress | Flour | +10kg @ $1.00/kg | $10.00 | |
| Work in Progress | Work In Progress | Water | +7kg @ $0.03/kg | $0.21 | |
| Work in Progress | Work In Progress | Salt | +200g @ $2.00/kg | $0.40 | |
| Work in Progress | Work In Progress | Starter | +2kg @ $1.00/kg | $2.00 | |
| Raw Materials | Storeroom | Flour | -10kg @ $1.00/kg | $10.00 | |
| Raw Materials | Storeroom | Water | -7kg @ $0.03/kg | $0.21 | |
| Raw Materials | Storeroom | Salt | -200g @ $2.00/kg | $0.40 | |
| Raw Materials | Storeroom | Starter | -2kg @ $1.00/kg | $2.00 |
As the bakers mix and bake the bread, they record their time through Job Cards. While Job Cards track the time spent at each Workstation, they don't generate any accounting entries themselves. Instead, ERPNext uses this time information along with the Workstation's standard rates to calculate the manufacturing costs when the bakers complete the bread.
The final Manufacture Stock Entry does two important things: it moves the materials from Work in Progress to Finished Goods, and it adds the standard labor and overhead costs based on the recorded Workstation time:
| Account | Warehouse | Stock Ledger | Debit | Credit |
|---|---|---|---|---|
| Inventory on Hand | Finished Goods | +19 @ $1.58 | $30.03 | |
| Work in Progress | Work in Progress | -20 @ $0.63 | $12.61 | |
| Expenses Included in Valuation | $19.00 | |||
| Inventory on Hand | Quarantined, Scrap and Rejected Items | +1 @ $1.58 | $1.58 |
The "Expenses Included in Valuation" account and nomenclature has an unfortunate name - it suggests storage or holding costs, but actually represents the contributory value of the company's manufacturing activities. In our example, this includes both direct labor ($15.00/hr) and electricity ($0.20/hr) from the Mixer Station and Baking Station, totaling $15.20 per hour.
In this process, input materials maintain their existing valuation method (like moving average) and any cost adjustments they may have received (such as from Landed Cost Vouchers). When transferred to Work in Progress, they carry their actual cost basis, not a standard cost. Only the labor and overhead rates from the Workstation are applied at predefined rates.
The resulting unit cost of $1.58 per loaf represents:
- The actual cost of input materials based on their valuation method
- Plus labor and overhead costs calculated from Workstation rates
- Divided across both good output (19 loaves) and scrapped items (1 loaf)
Scrap Inventory can be handled with either or both of a discrete account (a Stock account type) and/or a discrete Warehouse. This will reflect the value of inventory that may be potentially recoverable before it is disposed, typically with a Stock Reconciliation.