Preheat oven to 375 degrees Fahrenheit.
In a food processor, blitz together onions and mushrooms until they reach a crumbly consistency (like a ground meat). Transfer to a saucepan and let cool for 3-5 minutes.
Add spinach and cover. Cook until the spinach has most wilted – about 5-8 minutes. Remove any excess water. Let cool.
In a large bowl, whisk together the eggs and milk until fully incorporated. Mix in shredded cheese and salt.
Add mushroom mixture and distribute ingredients. (Make sure the mushroom mix is cool, so the eggs don’t cook prematurely).
Line a cupcake tin with cupcake wrappers (silicone or paper). Pour the egg mixture into each cavity so that it is ⅓ filled.
Bake for 15 minutes.