Salting water enhances the flavor of the food being cooked in it and can also raise the boiling point of the water, though the latter effect is minimal in most home cooking scenarios.
The primary reason recipes call for salting water is to season the food being cooked. When you cook pasta, vegetables, or potatoes in salted water, the salt is absorbed into the food, enhancing its natural flavors from the inside out. This is especially important for foods that don't have a lot of inherent flavor of their own. The salt penetrates the food more evenly than if you were to only season it after cooking.
While it's often mentioned that salt raises the boiling point of water, the amount of salt typically added in cooking has a negligible effect on the boiling point. You would need to add a very significant amount of salt to see a noticeable difference in boiling temperature. The flavor enhancement is the key benefit in most culinary applications.
Don't be afraid to salt your pasta water generously! It should taste like seawater. This ensures that the pasta is properly seasoned throughout, resulting in a much more flavorful dish. Undersalted pasta is a common mistake that can make even the best sauce taste bland.