in mistake for (something)
Mistaking one thing for something else. Manufacturers are being forced to package laundry detergent pods in childproof packaging, following a number of incidents in which young children have eaten the small, colorful products in mistake for candy. The defendant claims he simply grabbed the bag of narcotics in mistake for his own.
in miˈstake for something
thinking that something is something else: Children may eat pills in mistake for sweets.