Put the onions and oil in a large frying pan and fry for about
20 minutes, or until golden brown and very soft. Meanwhile,
boil the eggs for 8–10 minutes until hard-boiled. Remove the
pan from the heat, drain and then cover the eggs with cold
water. When just cool enough to handle, peel the eggs and grate
into a large bowl using the coarse side of a grater.
Spoon the onions onto the egg, leaving most of the oil in the
pan. Season generously with salt and pepper, and combine the
onions and egg with your hands or a wooden spoon, tasting as
you go. If too dry, add a little oil from the pan. The mixture
should stick together if pressed with your hand, but should not
be overly oily.
Cover with plastic wrap until ready to serve, pressing the wrap
onto the surface of the egg and onion so it doesn’t dry out.
Keep at room temperature if using the same day, otherwise refrigerate. Serve with challah or bagels.