Around the time of the dot-com boom, the expense of work snacks was first transferred to employers, at least in some white-collar industries. Free snacks at work are strongly associated with the profligacy of Silicon Valley, but the precise origins of the perk are unknown.

At many companies, employees can partake of a few kinds of free snacks . (The New York Times offers a limited assortment — fruits, pretzels, Goldfish — on a daily basis.) The start-ups NatureBox and SnackNation streamline the snack buying process for some employers, delivering automatic monthly orders of newfangled munchables like Aged Cheddar Lentil Loops, Blueberry Almond Quinoa Bites and Bohana Popped Water Lily Seeds.

There are limits to what kinds of foods employers are allowed to provide for their employees if they want those purchases to be tax-deductible. According to Section 119 of the Internal Revenue Code, a business can deduct occasional employee meals, but only when those meals are “furnished for the convenience of the employer.” Meals furnished for the convenience of the employee, on the other hand, are seldom allowed as a business expense.

Free snacks belong to a third category of cheap and infrequent perks called de minimis fringe benefits. The I.R.S. doesn’t tax these because, well, it’s tedious to determine their value. Up until last year, an employer could actually deduct the full cost of employee snacks, which might help to explain how they became a workplace fixture. In 2018, this tax break was halved, following the Tax Cuts and Jobs Act of 2017. It is too early to predict how the new set of rules might affect the future of the start-up smorgasbord. For now, employees of Yelp continue to enjoy a wide range of sweet and savory options.

“We’ve got roast beef, turkey, ham and different types of bread,” said Michael Sztanski, a sales manager. “We have bagels. We have a lot of frozen food, like burritos.” Also: iced tea, coffee, chips, hummus and hard-boiled eggs.

At lunchtime, Mr. Sztanski and his colleagues often joke that they feel like they’re playing a game of “office ‘Chopped’” — a reference to the popular TV franchise in which contestants cook meals with limited ingredients. His most prizewinning lunch is “a make-your-own-bowl-type thing,” in the style of fast-casual restaurants like Dig Inn and Sweetgreen.