There are many different types of insurance for cars. Many are optional, at least under the law. In practice, some of the supposedly "optional" policies end up being required for most people in order to finance the car. For that matter, some of the supposedly mandatory forms of car insurance can also be foregone, at least in some states, assuming you make other arrangements to cover your obligations in the event of an accident. Below are some of the insurance types of car insurance you may need or want, starting with the ones you are most likely to be required to have.
Protection for Other People - Liability
Liability insurance pays damage to the other party in cases where you are held to be legally liable or at fault for an accident. For most people in most states, Liability insurance is mandatory under the law in order to protect people from the consequences of irresponsible drivers. However, some states do allow individuals to forego Liability insurance provided they make other arrangements to cover the other party in case of an accident, like taking out a large bond. If you aren't wealthy enough to set aside a large chunk of change in the form of a bond, you can generally assume you will be required to carry this type of insurance.
There are two types of liability insurance - Bodily Injury and Property Damage Liability. The first pays in cases where someone else was hurt. The second pays in cases where someone else's property was damaged. In most cases this will be their vehicle but it might also be other property like a mail box or fence. Both types are generally mandatory under the law in most states.
Protection for Your Own Car - Collision and Comprehensive
Liability insurance pays out if you do something bad to someone else. Collision and Comprehensive pay out if something happens to your vehicle they both cover physical or property damage, not injuries. Collision covers damages to you vehicle in case of an accident involving another vehicle. Comprehensive pays for incidents which damage the vehicle but do not involve another vehicle. This includes things like hitting a tree or deer, vandalism, and hail.
Collision and Comprehensive coverage are nominally "optional". In other words, they are not required by the state. In practice, most people are required to carry this type of coverage because most people cannot afford to pay cash for a car. If you have to finance your car in order to purchase it or you are leasing the vehicle, the financing company will require you to get Collision and Comprehensive coverage in order to protect themselves financially in the event something happens to the vehicle. So the odds are high that you will need both of these as well. They are usually sold as a package deal.
The four above are the usual suspects -- the type of insurance most people carry for their vehicle. Below is a really quick run-down of other types of insurance which are a bit less common.
Uninsured or Underinsured Motorist
There are four different types of policies which all pay benefits in case you are the victim of a hit and run or were hit by someone else and they either are not insured or their insurance isn't enough to cover the damages: Uninsured Motorist Personal Injury; Uninsured Motorist Property Damage; Underinsured Motorist Personal Injury; and Underinsured Motorist Property Damage. It should be obvious from their names what each does.
Miscellaneous
There are quite a few other types of specialized car insurance which cover things like accidental death, additional medical coverage, mechanical breakdown, towing and labour, custom parts and so forth. For many of them, it is fairly obvious from their name what they cover. They aren't all that commonly used. One that may not be obvious from its name is called Gap coverage. Gap insurance covers the difference between the amount you will be paid if the car is declared "totalled" and what you still owe on it so that if the car is a total loss, your loan can be paid in full and you won't still owe money on a car you no longer have.

