When a consumer has indifference preference.
Opportunity cost can be defined as cost forgone for one unit of a commodity during the purchase of one unit of another commodity.
Suppose in a food stall there are chips and burgers, and you would like to have chips for a light snack; therefore, you will buy chips. The amount you paid for buying one pack of chips is the cost you have sacrificed by not buying a burger.
Hence, the opportunity cost is zero when a consumer has indifference preference. For example, if you want to purchase a watch, you might come across varieties of watches; you would choose one specific watch, but you won’t spend money on shoes. So you are indifferent to varieties of watches. Thus, your opportunity cost for rejecting one brand and selecting the other brand of watch is zero. Of course, the cost price of the watches have to be equal; in the case of different prices but same quality: the preferences inclined towards the cheaper one.