A faulty gas cap can cause the check engine light to come on. It can trigger a fault code in the vehicle's onboard diagnostic (OBD) system, which can cause the check engine light to come on.