Heat the oven: Heat the oven to 350°F and grease a 2-quart or 9x9-inch baking dish.
Cook the squash and onion: Melt the 2 tablespoons of butter in a large skillet over medium heat. Add the squash, onion, salt, and pepper and cook for 10-12 minutes, stirring often, until the squash slumps and turns translucent at the edges.
Drain it hard: Dump everything into a colander set in the sink and let it sit 5 minutes, then press down firmly with the back of a spoon to push out the liquid. You should get 1/2 cup or more. This step decides whether the casserole is creamy or soupy.
Mix the base: Whisk the eggs, sour cream, and mayonnaise together in a large bowl until smooth, then stir in the shredded cheddar.
Combine: Fold the drained squash and onion into the egg mixture until everything is coated, then spread it evenly in the prepared dish.
Butter the crumbs: Toss the crushed crackers and parmesan with the 3 tablespoons of melted butter in a small bowl until the crumbs look damp, then scatter them over the top.
Bake: Bake for 30-35 minutes, until the topping is deep golden, the edges bubble, and the center reads 160°F on a thermometer and no longer jiggles when you nudge the dish. If the crumbs brown before the center sets, tent the dish loosely with foil. Let it rest 10 minutes before serving.
Notes
Drain the cooked squash in a colander and press the liquid out before it goes into the egg mixture, or the casserole will be watery. Bake at 350°F until the topping is deep golden and the center reads 160°F on a thermometer and no longer jiggles, 30-35 minutes. Tent with foil if the crumbs brown before the center sets.