Opportunity cost refers to what you miss out on by going with one option over another comparable option. The concept is an important part of economic and financial planning, and making decisions with opportunity costs in mind helps ensure that funds, resources, and time are put to optimal use.

The opportunity cost of past actions can be found using the formula below:

Opportunity cost = The return from the unchosen option - The return from your chosen option

An example of opportunity cost

Imagine a situation in which you paid $1 for a chance to choose between two mystery packages that each contained an unknown number of cookies. Let's say that you chose a package that contained one cookie, while the other package contained three cookies. There would be an opportunity cost of two cookies for going with your chosen package -- the number of additional cookies that you missed out on by not going with the other package.

Opportunity costs are sometimes confused with trade-offs, but these two terms have different meanings in economics. A trade-off is what you have to expend in order to pursue an option, while an opportunity cost is what you miss out on by not pursuing a better option.

In the cookie example above, the trade-off for selecting either of the two mystery packages was the same: You paid $1. However, you lost out on two additional cookies by not going with the other package, so there was a significant opportunity cost even though the trade-off was equivalent.

For investments you plan to make in the future, there often won't be a simple, reliably accurate formula for calculating the opportunity cost. This is because you don't know for certain how the assets you are comparing will perform over time.

Disintegrating dollar sign

Image source: Getty Images.

Three key concepts related to opportunity cost

Cost, time, and effort are generally the core dimensions along which opportunity cost can be calculated. Within the broader category of opportunity cost, there are subcategories and related concepts that are important in business and economics. You'll find a breakdown of some of the more common examples below:

  • The law of increasing opportunity costs states that opportunity cost rises if you are producing a good and opt to produce more of that good. If you have a factory that is producing cookies, there are rising costs associated with increasing your production above normal levels. That also means that there is a rising opportunity cost for not producing an item that would sell better or be more profitable.
  • Marginal opportunity cost is a measurement or estimation of the opportunity cost involved with producing more of a particular good. Increases to marginal opportunity cost can become smaller or larger as you produce more goods, depending on the conditions. For example, the cost of materials per unit may decrease if materials are purchased in greater quantities, but labor may become more expensive if overtime needs to be paid. 
  • Comparative advantage refers to a company's ability to produce goods or services at a lower opportunity cost than its competitors. If Company A can produce cookies for the same amount of money as Company B but sell them at a higher price due to higher quality or better branding, Company A has a comparative advantage when it comes to producing cookies because its superior return means there is a lower opportunity cost for not producing a different item.  

Opportunity cost and investing

If you buy $1,000 worth of stock in a company, the basic cost is pretty obvious -- $1,000. However, you might also want to consider the possibility that your funds could be put to better use, and you'll be able to calculate the opportunity cost of your decision in retrospect.

If the stock you purchased remains perfectly flat over the course of a year, it might not bother you much. However, if another stock you were thinking of investing that $1,000 in goes on to have a great year and triples in price, you'll likely be upset by the opportunity you lost by investing in a company that underperformed compared to the alternative option you were considering. 

The alternative stock would have yielded a profit of $2,000, while the stock you actually bought yielded zero profit. Your investment didn't lose money, but in retrospect you can see that there was an opportunity cost of $2,000 for not buying the other stock instead. 

In the stock example detailed above, having to pay $1,000 to acquire the stock is the trade-off. The trade-off to acquire either of the stocks in question would have been the same, but not going with the better performer had an opportunity cost.