That’s easy: the egg came first.
Chickens have been traced back genetically to an earlier bird in Indochina called the “red jungle fowl.”
At some point one of these jungle foremothers laid an egg that had genetic mutations within it.
The mutations were severe enough that the bird that hatched would have to be considered more of a chicken than a red jungle fowl. Hence, the egg came first.
How long ago was that? We’re not sure, but we do know that people first domesticated the chicken about eight thousand years ago in Thailand.