1. Preheat oven to 350 degrees F. In a large nonstick skillet, heat oil over medium heat but not smoking. Add onion; cook, stirring constantly, until softened, about 10 minutes. Add zucchini; cook, stirring frequently, until tender, about 10 minutes longer.
2. In a medium bowl, combine ricotta, basil, salt, and pepper. Mix well.
3. In a 1-1/2 quart casserole, alternate layers of zucchini mixture and ricotta mixture. Top with Parmesan. Bake casserole until golden brown, about 40 minutes. Serve immediately.