To prevent it from drying out, make sure there’s enough sauce to coat the pasta, cover it with foil for the first part of baking, and add cheese or a sauce on top to help retain moisture.