As a general rule, even if the Torah forbids a certain food, one is still permitted to eat kosher food that has been artificially flavored to taste like that food. However, if it closely resembles the actual non-kosher food, it may be necessary to mark it as an imitation so no one will be confused.

Tastes Like Milk and Meat

Our first port of call is a fascinating incident in the Talmud:

Yalta once said to her husband, Rabbi Nachman: “Now, let us see, whatever G‑d forbade us, He permitted us something corresponding. He forbade blood but permitted liver. . . . He forbade pork but permitted the brains of a shibuta.1 . . . I would like to eat something that has the taste of meat cooked with milk.” Rabbi Nachman ordered the chefs to skewer [cow] udders and roast them.2

The commentaries explain that for every forbidden food or act, G‑d provided another similar permitted food or act with the same pleasurable sensation as the forbidden one. Why? Because G‑d is not out to deny us the pleasure inherent in that food or act; rather, the sin itself is essentially forbidden.3

But there are a few important caveats before you dig in.

Kosher Certification

As always, you need to make sure the product has a reliable kosher certification. In fact, there is imitation crab on the market that actually contains real crab. (It is mostly made of white-fleshed fish, but is flavored with real crab.)

What Will People Think?

There is a concept in Jewish law called mar'it ayin (lit. "appearance to the eye"). Certain acts are prohibited just because observers mistake them for different, forbidden acts, causing them to either think that the act is in fact permissible or to view the person negatively. Generally, even if something is forbidden because of mar'it ayin, it may not even be done in the privacy of one's home.4

However, since the reason for this prohibition is only because of how the act can appear to others, if one takes certain necessary precautions, one is permitted to do the act.5

Meat and Non-Dairy Milk

For example, if one wishes to drink almond milk while eating meat, he needs to indicate that it is in fact almond milk, not regular milk, which is forbidden. In the olden days, this was done by popping some whole almonds into the milk. Today, this can be achieved by having the container on the table, making it clear that it is almond milk.6

The same would need to be done in order to serve a veggie burger that resembles meat, topped with real cheese, or to serve a beef burger under a slice of imitation cheese. It’s fine to eat, provided that the package is nearby and visible, or its parve identity is spelled out on the menu, receipt, etc.

Mock Pork

This principle would also extend to foods that were made to resemble pork. If it is certified kosher, you can eat it if the viewer can easily see evidence of its non-porcine provenance.

Parve Ice Cream

In the event that the imitation item has become ubiquitous to the point that observers would not assume you’re doing something forbidden, it is permitted to eat it even without any special markers. Thus, according to many, there is no issue with a parve ice cream dessert after a meat meal.7 Many kosher certifiers are of the opinion that the same holds true for surimi (mock crab). Since many, both Jews and non-Jews, know that surimi exists, it does not need to be marked when served on a kosher table.

Nevertheless, if you’re eating one of these imitation foods in the company of people who are unaware that these products exist, make it a point to inform them so that they do not jump to conclusions.

The Real Thing

These days, imitation products approximate forbidden foods, but believe it or not, the real thing won’t always be off the table. As the Midrash says: “Why is the pig called [in Hebrew] chazir? Because in the future, G‑d will return [lehachazir] it to Israel.”8

In other words, in the messianic era, the world will be purified and elevated to the extent that the pig will become permissible to eat. (While there is a rule that the laws of the Torah will never change, commentaries explain that G‑d will alter the pig’s physiology so that it will chew its cud and therefore bear both kosher signs.9)

Read more about pigs and Judaism here.

May we merit the coming of the Moshiach speedily in our days!