Chop onions into quarter rings (or as you like). Heat 3 tbsp olive oil in a pan over medium heat, add onions with a pinch of salt, and fry for 20–25 minutes, stirring often, until deep brown.
Meanwhile, bring water to a boil. Gently place eggs in the boiling water with a spoon and cook for about 9-10 minutes. Cool in ice water for 5 minutes, then peel and dice or mash with a fork.
Mix eggs, caramelized onions (with the oil), mayonnaise, and mustard. Taste and adjust seasoning with black pepper or herbs like dill, chives, parsley, or celery leaves.