Cook spaghetti according to package instructions. Drain and set aside.
In a skillet, sauté onion in butter or olive oil until soft and fragrant.
In a large bowl, combine cooked chicken, soup, Rotel, sour cream, garlic powder, onion powder, salt, and pepper. Stir until smooth and creamy.
Add cooked spaghetti and half of the cheese. Mix until the pasta is evenly coated.
Transfer mixture into a greased casserole dish. Sprinkle the remaining cheese on top.
Bake at 350°F (175°C) for 25–30 minutes, or until bubbly and golden brown.
Serve warm, garnished with fresh parsley or green onions if desired.