Companies with inventory often use the weighted average method for calculating inventory costs. The weighted average method is based on the total costs of the inventory on hand and the total quantity of goods on hand. This method is one of several common methods used for calculating inventory costs. Two other common methods include the first-in-first-out method and the last-in-first-out method. When a company uses the weighted average method, it is normally calculated at the end of each accounting period.

Take a physical inventory count. In order to use the weighted average method to calculate the unit price of goods, the company must take a physical inventory count to determine how many goods are on hand. If a physical inventory count is not taken, the company can calculate a close estimation of the number of goods on hand by beginning with the quantity at the beginning of the year. Add the purchases, in terms of quantity, to this number. Subtract the units sold and that should be a close estimation of the ending quantity on hand.

Add up the total costs of these goods. Looking through invoices, add up the total amount of the costs for all products. For example, if you had three purchases of goods throughout the year, add the total costs for these invoices. If you purchased 100 widgets for $10 on the first invoice, the cost is $1,000. If the next invoice has 200 widgets for $12, the cost is $2,400 and the third invoice is 300 widgets for $11, the cost is $3,300. The total of these three orders is $6,700.

Divide the cost by the items purchased. To find the unit cost of each item, divide $6,700 by the total quantity purchased which is 600. This equals around $11.16 per unit.

Calculate the value on hand. If the physical inventory count shows that there are 100 widgets left, the value of these are found by multiplying 100 times the unit cost of $11.16; which equals $1,116. The total cost of the 500 that were sold is found by multiplying 500 times $11.16; which equals $5,580.