Preheat oven to 350°F (175°C). In a skillet, heat olive oil over medium heat and sauté onions until translucent, about 3 minutes.
Add sliced mushrooms to the skillet and cook until tender and slightly browned, about 5 minutes. Season with salt and pepper.
In a large bowl, whisk eggs until smooth. Stir in parsley and shredded cheddar cheese.
Add the cooked mushrooms and onions into the egg mixture and mix gently.
Pour the mixture into a greased oven-safe dish or muffin tins. Bake in the preheated oven for 15 to 20 minutes or until eggs are set and lightly golden on top.
Remove from oven, let cool slightly, then slice or remove from muffin tins and serve warm.
Notes
For a dairy-free version, omit the cheese or substitute with a vegan cheese alternative.