Dashboard warning lights create uncertainty for many drivers because it is not always clear how urgent the issue really is. The best first reaction is simple: do not panic, but do not ignore it either.
Red warning lights usually indicate a greater need for immediate action than yellow or amber ones. If a warning related to oil pressure, cooling or braking appears, it is wise to stop safely as soon as possible and assess the situation.
A yellow light usually does not mean the car must stop instantly, but it still means the vehicle wants attention. If you leave it alone for too long, a smaller issue can become a larger and more expensive one.
A very practical habit is to note the date, mileage and symptoms in the service history when a warning first appears. That makes it much easier later to understand when the issue started and what was eventually done to solve it.