Echoing ^^^.
As someone liscened by the State to legally sell the eggs and meat my chickens produce, I can attest to this first hand. Even buying from the local mill, non-organic, I can't get feed cheap enough to do better than break even during the good months in the year I started. Feed costs are WAY up. Egg prices at the grocery have not grown near so much.
Rough estimates? A Layer will eat 20 pounds in its first 20 weeks, then about 2#/wk thereafter. Most will produce nothing for their first 20 weeks, till start of lay - many birdsd won't start till later.
So your first full year of owning a layer bird, you can expect it to eat about 80# of feed. Assuming it drops a useful egg 5 days of 7, beginning week 20, you are looking at 160 eggs in that same period - about 13 dozen.
At $3/doz, that's almost $40. 80# of gmo name brand feed from the farm store is likely somewhere between $32 and $45 right now. So you have the *potential* of a slight profit. Until you consider the cost of buying the bird in the first place, the expense of their facilities, your labor time, the risk of loss to predator, disease, injury, power, water, licensing, advertising, packaging, cleaning materials, and costs of refrigeration...
What do those cost? Even with feed costs down at $0.28/lb ($14/50#) and hatching my own birds, I only break even a few months out of the year. I eat my excess males, and invoice myself $1.50/lb (bone in) for them.
My flock is my entertainment budget for the year.