Monthly cost accounting

A complete feature guide for the monthly cost accounting workbench. From first-in, first-out (FIFO) material cost calculation and automatic verification to anomaly detection and difference journal entries, this guide explains how to dramatically streamline monthly financial closing for small and medium-sized manufacturers.

5 min

What this feature can do

This function calculates the actual cost required for monthly financial reporting in the manufacturing industry.

  • Material costs are calculated using the First-In, First-Out (FIFO) method, where materials are consumed sequentially in lot units.
  • Labor costs are calculated based on actual working hours, and indirect costs are calculated according to allocation rules, and these are included in the cost of goods sold.
  • You can review the difference between standard cost and actual cost, and also compare it with the previous month.

FIFO (First-In, First-Out): A method of calculating costs by assuming that materials are used in the order they were purchased. It is one of the industry standard calculation methods.

Traditionally, many small and medium-sized manufacturers have used spreadsheets to calculate monthly costs, manually performing first-in, first-out (FIFO) calculations for material costs, spending more than half a day allocating indirect costs, and finally visually verifying the calculations—a burdensome process that they repeat every month. This function allows you to perform this entire process with a single click, and the system completes everything, including automatic verification.

Screen URL:

  • Cost Workbench:/app/costing-workbench
  • Execution Workbench:/app/costing-execution-workbench

Monthly Cost Accounting Workbench — Selecting a period expands the summary card and navigation links.


Three challenges this feature solves

Problem 1: Cost accounting stops due to missing data entry at the site.

In manufacturing environments, performance data is sometimes registered without the information linking each task to "which final product it is intended for."

Solution for this system: Automated inference for the final product

During cost calculation, the system automatically traces back the process tree for each container (unit of work-in-progress) and infers and completes the final product code. This prevents cost "getting lost" without increasing the input burden on the factory floor.

Problem 2: Indirect cost allocation results in errors in irregular months

"This month, production was zero due to maintenance, but indirect costs were incurred." — In cases like this, the allocation calculation can result in a division by zero error, which can halt the monthly closing process.

Solution for this system: Automatic avoidance of division by zero

The allocation service does not generate an error even if production figures are zero. Instead, it automatically allocates indirect costs to the ending work-in-process inventory (remaining work-in-process inventory). If there is no ending work-in-process inventory, it is recorded as unallocated in the verification log, and the decision is left to the person in charge.

Challenge 3: Monthly processing is a one-shot deal and scary.

"The calculations turned out to be wrong, but there's no going back"—this kind of fear is a major source of stress during monthly financial closing.

Solution for this system: Non-destructive "back-bookkeeping" method

This feature does not rewrite any of the standard inventory ledgers or accounting ledgers in ERPNext. Because calculations are performed on an independent "back-end ledger," you can modify allocation rules and actual data and recalculate as many times as you like. It is designed to be safe by posting only the final confirmed difference as a journal entry.


Overall Flow

期間を作成 → 期首残高を繰越 → 計算を実行 → 検算 → 差額レビュー → 仕訳作成 → 期間をクローズ

ScreenURLPurpose
Cost Workbench/app/costing-workbenchCreating, managing, and calculating time periods
Execution Workbench/app/costing-execution-workbenchCheck the calculation progress
Material Consumption Flow/app/costing-fifo-flowConsumption order and unit price trends of materials (first-in, first-out)
Work-in-Progress Inventory Summary/app/costing-wip-summaryWork-in-Process Costs by Process and Item
Work-in-Progress (by element)/app/costing-wip-element Breakdown of material costs, labor costs, and indirect costs
Opening Balance/app/costing-opening-wipConfirmation and Carryover of Beginning Work-in-Process Inventory Balance
Allocation Preview/app/costing-allocation-previewIndirect Cost Allocation Simulation
Allocation Results/app/costing-allocation-resultConfirmation of results after allocation
Verification Summary/app/costing-validation-summaryCost consistency check results
Verification Details/app/costing-validation-detailIndividual details of verification errors
Price Difference Review/app/costing-variance-reviewDifference between standard cost and actual cost / compared to the previous month

Operating Procedure

Step 1: Create cost periods

1./app/costing-workbench Open 2. Click the "New Period" button. 3. Select the target month and year (e.g., January 2026) 4. The cost period is created in an "open" state.

Step 2: Carry forward the opening balance

  1. Click the "Beginning Balance Carryover" button.
  2. The work-in-progress balance at the end of the previous month is automatically copied as the beginning balance for the current month.

Confirmation screen:/app/costing-opening-wip

ItemContents
Item CodeWork-in-Progress Item
Lot NumberLot Identifier
QuantityCarryover Quantity
Material CostsMaterial costs at the beginning of the period
Labor CostsLabor costs at the beginning of the period
Indirect CostsIndirect Costs at the Beginning of the Period

Opening balance

Step 3: Check the allocation of indirect costs in the allocation preview (optional)

Before performing the actual calculations, you can simulate the allocation of indirect costs.

1./app/costing-allocation-preview Open 2. Check and edit the amount of the indirect cost pool. 3. Check the value of the allocation driver (allocation criteria). 4. Preview the allocation amount and percentage for each item. 5. Modify the values ​​as needed and click "Save" to apply the changes.

Allocation Preview

Step 4: Perform cost accounting

  1. Click the "Execute Cost Calculation" button.
  2. The calculation starts in the background.
  3. The progress bar displays the progress of the calculation steps in real time.

You can perform other tasks in your browser while the calculation is in progress. You will be notified by an alert when it is complete.


Steps in Cost Accounting

The calculation process is executed sequentially in the following 8 steps. Users only need to check the progress bar to see the status.

StepProcessing Details
0Load opening balance
1Extract the movement of work-in-progress (collect container creation and consumption history)
2Identify which finished product each container leads to
3Track the order of raw material consumption using first-in, first-out (FIFO) method
4Calculate material costs (using first-in, first-out unit prices)
5Calculate labor costs (working hours × hourly rate)
6Allocate indirect costs (proportionately according to allocation rules)
7Cost of work-in-progress is compiled by process and item
8Verification (checking the consistency of costs)

Checking Progress

The progress of each step is reflected on the screen in real time.

DisplayContents
Step NameCurrently Executing Step
Number of items processedNumber of items processed / Total number of items
Overall progress0% → 100%

The three elements of cost

① Material cost (direct material cost)

  • Total the value of the materials (lots) consumed in each process.
  • Calculated using the First-In, First-Out (FIFO) method, assuming consumption in the order of oldest purchases.
  • The unit price in the receipt record will be used as the basis for the calculation.

② Labor costs (direct labor costs)

  • The actual work time is calculated from the time records on the process cards.
  • Calculated as: Equipment hourly rate × Actual hours worked
  • It is allocated to each process (work in progress).

③ Indirect costs (manufacturing overhead costs)

  • Register the expense items and amounts in the indirect expense pool (utilities, equipment depreciation, etc.).
  • Allocation based on allocation drivers (numerical values ​​used as allocation criteria: work time, production quantity, etc.)
  • Calculation formula: Indirect costs × (Allocation base value for the target item ÷ Sum of allocation base values ​​for all items)

Advanced analytical capabilities to identify opportunities for cost improvement

Monthly cost accounting isn't just about "getting the numbers and being done with it." This system incorporates a mechanism to automatically detect cost anomalies and areas for improvement.

Automatic detection of abnormal lot numbers

Material consumption flow screen (/app/costing-fifo-flow The system compares the unit price for each lot to the average unit price and automatically displays a warning mark (⚠) for lots with a deviation rate exceeding 20%. This allows you to instantly identify input errors or abnormal price increases from a vast amount of lot data.

Material Consumption Flow Screen — Product Line-Specific Collapse and Cost Waterfall

Understanding the cost of defective waste (scrap)

While typical systems treat the cost of defective products as zero, this system logically allocates the material and processing costs invested in defective products. This allows you to accurately determine "how much monetary loss was incurred due to defects this month" and numerically evaluate the cost-effectiveness of quality improvement measures.

Material Cost Drill-Down Tracking

"The cost of this semi-finished product is high, but which raw material is the cause?" — To answer questions like this, we can break down material costs using a proportional allocation based on the amount of material consumed, and trace the factors causing the cost increase in a tree-like structure.

Review compared to the previous month

Difference Review Screen (/app/costing-variance-review This feature automatically compares the costs of the current month and the comparison month, broken down into three components: material costs, labor costs, and indirect costs. The fluctuation rate badge display allows you to easily identify processes and product numbers with significant cost fluctuations.

Display itemsContents
Current month's unit price / Comparison month's unit priceUnit price trend by process and model number
Unit price differenceFluctuation in absolute amount
Fluctuation RatePercentage Display (Color-coded Badges)
Difference between material costs, labor costs, and indirect costsBreakdown of fluctuations by three elements

Difference Review Screen — Month-on-Month Comparison: February 2026 vs. January 2026


Eliminate manual verification with 3-layer automated verification.

In the final step of cost accounting (Step 8), the system automatically performs the following consistency checks. This eliminates the manual verification work that was previously done by humans in spreadsheets.

ChecklistContent
Debit and Credit BalanceInput Cost = Cost of Finished Goods + Cost of Ending Work-in-Process Inventory
Material Cost ConsistencyTotal materials consumed using the first-in, first-out (FIFO) method = Total materials cost recorded
Quantity MatchingInput Quantity = Finished Quantity + Work in Progress Quantity + Loss Quantity

The verification result is/app/costing-validation-summary The list is displayed, and if there is an error, the cause and the affected data are shown on the details screen./app/costing-validation-detail You can check it there.

Verification Summary


Results Confirmation Screen

Material Consumption Flow

/app/costing-fifo-flowThis allows us to visualize the consumption of materials over time.

ItemContents
Lot NumberLot Identifier
Purchase dateMaterial arrival date
Purchase priceUnit price in receiving record
Input QuantityBeginning Balance + Purchases for the Current Month
ConsumptionQuantity consumed this month
Remaining balanceEnd-of-month balance
Breakdown by MaterialBreakdown of how much of each material was consumed in each process

CSV Download: You can export the data as a CSV file using the "CSV Download" button.

Work-in-Progress Inventory Summary

/app/costing-wip-summaryThis allows you to check the work-in-progress cost by process and item.

Work-in-Progress Inventory Summary

ItemContents
Final ProductItem Code of the Finished Product
Process (Work in Progress)Work in Progress Item Code
Material costDirect material cost
Labor costsDirect labor costs
OverheadManufacturing overhead
Total CostSum of 3 Elements
QuantityQuantity of work-in-progress
Unit PriceTotal Cost ÷ Quantity

Work in Progress (by element)

/app/costing-wip-elementNext, we will show the breakdown of work-in-progress costs by three elements: material costs, labor costs, and indirect costs.

Work in progress (by element)

Price Difference Review

/app/costing-variance-reviewThis allows us to analyze the difference between standard cost and actual cost.

Comparison axisContents
Difference in material costsStandard material cost (BOM) vs. First-in, first-out (FIFO) actual material cost
Difference in labor costsStandard processing costs vs. Actual labor costs
Difference in indirect costsStandard indirect costs vs. Actual indirect costs after allocation
Total DifferenceSum of 3 Elements

Review compared to the previous month

We will compare the results with those of the previous month and analyze the factors influencing the cost fluctuations.

ItemContents
This month's/Previous month's costComparison by material costs, labor costs, and indirect costs
Difference between fluctuation amount and absolute amount
Rate of changeDifference in percentage

Creating the difference journal entry

Clicking the "Create Journal Entry Draft" button on the difference review screen will automatically generate a cost difference journal entry to adjust the difference between the back ledger and the standard ledger.

  1. Create a draft journal entry on the difference review screen.
  2. Set up variance accounts and cost centers in cost variance journal entries.
  3. After approval, post the entry to the general ledger as a journal entry.

Closing of Period

Once cost accounting is complete and there are no problems with the verification, the period is closed.

  1. Click the "Close Period" button.
  2. The status of the cost period changes to "closed".
  3. Once closed, changes cannot be made in principle (only administrators can reopen it).

CSV Output

You can export the following data as an Excel-compatible CSV file (UTF-8 with BOM) from the "CSV Output" menu in the workbench.

CSV TypeContent
Material Consumption LotCost Details by Lot (with Deviation Rate and Anomaly Flag) + Cost Waterfall
Work-in-Process Inventory Valuation by ProcessBeginning, Input, Output, and Ending Quantities and Costs for Each Process and Part Number
Allocation ResultsDetails of Indirect Cost Allocation
Cost Difference DetailsList of Differences Between Backbook and Standard Ledger
Container history detailsCost traceability per container
Cost breakdown by productCost summary for each final product
Labor Costs and Time by ProcessWorking Hours and Labor Costs for Each Process
Details of auxiliary material consumptionAmount and cost of auxiliary materials consumed
Monthly TrendsMonthly Cost Trends

Tips for Use

  • Recalculation is always possible: Even during periods marked as "calculated," you can recalculate using the "Recalculate" button. You can try again as many times as you like after modifying allocation rules or correcting actual data.
  • Other operations are possible even while calculations are in progress: Cost calculation runs in the background, so you can operate other business screens even while calculations are being performed. Progress is updated in real time every 3 seconds.
  • Period Reopening: If an error is found, the administrator can reopen the period and recalculate it (the reopening history is automatically recorded).
  • Calculation Version Control: Each time a recalculation is performed, the version number is incremented, and when and by whom the calculation was performed is recorded.
  • Creating journal entries for the difference: From the difference review screen, you can automatically generate journal entries to adjust the difference by selecting "Create draft journal entry".
  • CSV Output: Material consumption flow data can be exported as a CSV file for detailed analysis in Excel.
  • Automatic recovery in case of errors: If an error occurs during calculation, the status will change to "Failed" and the error details will be saved. After correcting the cause, you can resume by clicking the "Recalculate" button.

Want to learn more?

If you have any questions about how to use the system, please get in touch. Our ERPNext implementation specialists will support you directly.