OBD-II

How to Clear OBD2 Codes Safely (and When NOT To)

Albert Carles — Hardware Engineer, OBD-II Specialist

Written by

Albert Carles

Hardware Engineer, OBD-II Specialist

Published Last updated 7 min read
How to Clear OBD2 Codes Safely (and When NOT To) — OBD-II guide

Key Takeaway

Want to clear that check engine light? Here's how to do it safely — and when you absolutely shouldn't.

Clearing OBD2 codes is safe AFTER you have repaired the underlying fault — connect the scanner, record the codes, and use Mode 04 to erase them. Do NOT clear codes before diagnosis (you lose freeze-frame data) or before an emissions inspection (resetting readiness monitors causes automatic failure). STEER lets you clear from your phone while preserving full code history.

How to Clear Codes

1. Connect your OBD2 scanner.

2. Read and record all stored codes first.

3. Select "Clear Codes" or "Erase DTCs" (Mode 04).

4. The check engine light turns off.

5. Drive normally — if the problem persists, the code returns within 1-3 drive cycles.

When It's OK to Clear Codes

ScenarioClear?Why
After completing a repairYesVerify the fix worked
Gas cap code after tighteningYesConfirm it was the cap
After battery replacementYesClear transient relearn codes
Known issue, monitoringYesReset to see if it returns
How to diagnose How to Clear OBD2 Codes Safely (and When NOT To) — OBD2 car scanner guide
How to Clear OBD2 Codes Safely (and When NOT To)OBD-II diagnostic guide

When NOT to Clear Codes

ScenarioClear?Why Not
Before diagnosisNoLoses critical information
Before emissions inspectionNoResets readiness monitors = automatic fail
Active misfire (flashing CEL)NoHides a dangerous condition
Selling a car to hide problemsNoUnethical and may be illegal

What Clearing Codes Also Resets

  • All stored DTCs and freeze frame data
  • OBD-II readiness monitors (need 50-100 miles to re-complete)
  • Fuel trim adaptive values (ECM needs to relearn)
  • STEER preserves code history when you clear

    A standard scanner clears the ECM, and the data is gone forever. The [STEER OBD-II adapter](/obd2-scanner/) syncs every code event to your phone before you clear, so you keep the full history — codes, timestamps, freeze frame, miles between events — even after the ECM is wiped. Useful when you are tracking an intermittent fault. See the [OBD-II codes pillar](/codes/) for full code references.

    Frequently Asked Questions

    Will clearing the check engine light fix my car?

    No. Clearing codes turns off the warning light and erases stored codes, but does not fix the underlying fault. Within 1-3 drive cycles, if the fault is still present, the code returns and the light reilluminates. The only reason to clear codes is to confirm a completed repair fixed the issue or to start a fresh observation period for an intermittent fault.

    How long after clearing OBD2 codes can I take an emissions test?

    Wait at least 100-200 miles of varied driving (city, highway, multiple cold starts) before testing. Clearing codes resets all OBD-II readiness monitors to "Not Ready," and most emissions inspection programs fail a vehicle with too many incomplete monitors (typically more than 2). The catalyst and EVAP monitors are the slowest to complete — they require specific operating conditions, partial fuel level, and stable ambient temperature.

    Will disconnecting the battery clear OBD2 codes?

    Older vehicles, yes — disconnecting for 5-15 minutes resets the ECM memory. Many modern vehicles (2010+) retain codes through battery disconnection because the ECM has internal nonvolatile memory for fault history. Even on older vehicles, battery disconnection is a bad way to clear codes because it also resets ECM adaptations, idle settings, radio presets, anti-theft codes, and OBD-II readiness monitors. Use a scanner instead.

    Can I clear permanent DTC codes?

    No, not directly. Permanent DTCs (P-codes flagged as PDTC in some scanners) are stored in ECM nonvolatile memory and cannot be cleared by Mode 04 or by battery disconnection. They clear automatically only after the ECM observes a configurable number of consecutive clean drive cycles confirming the fault is gone. This is intentional — designed to prevent owners from clearing codes immediately before an emissions test.

    Get plain-English answers on your iPhone

    STEER reads your car's codes the moment they trigger and translates them into something you can act on.

    Download on the App Store

    Related reads

    Keep going. These pair well with what you just read.