Modern cars and trucks have an automotive diagnostic system known as OBD-II (on-board diagnostics). This system monitors a number of engine and emissions-related components to ensure that everything is in working order.

If your gas cap is not properly attached, you may see a “Check Engine” light or a “Loose Cap” warning light on the dash.

You can either tighten the cap and wait for the system to reset itself when it determines the problem is fixed, or you can use an OBD-II code scanner to manually reset the system.