P0171 Diagnostic Guide

P0171 may mean Bank 1 fuel control is correcting lean and the PCM has reached a rich adaptive limit while trying to compensate.

Article vehicle: 2020-2025 Ford F250 Superduty 7.3GodzillaGas

Technical guidanceConfirm the exact vehicle configuration and follow applicable safety procedures before testing or repair.
P0171 P0171 Diagnostic Guide diagnostic guide

What this code means

P0171 may mean Bank 1 fuel control is correcting lean and the PCM has reached a rich adaptive limit while trying to compensate.

What the vehicle may do

  • The vehicle may idle rough or unevenly.
  • The vehicle may hesitate or feel down on power.
  • The malfunction indicator may be on with little noticeable drivability change.

Possible fault areas

  • Possible unmetered air, intake, vacuum, or PCV concerns.
  • Possible EVAP purge, EGR, or exhaust leak concerns.
  • Possible fuel delivery, fuel quality, ignition, or injector concerns.
  • Possible MAF input, oxygen sensor circuit, oxygen sensor, or modification-related concerns.

Diagnostic path

Opening: what P0171 is telling us

On this 2020 to 2025 F-250 with the 7.3 gas engine, P0171 means the PCM may be seeing Bank 1 fuel control pushed lean enough that adaptive correction has reached its rich limit. The truck may idle rough, hesitate, run unevenly, or sometimes only turn the light on with very little drivability change. Broadly, this can come from possible unmetered air, vacuum or PCV issues, EVAP purge flow, exhaust or EGR leaks, fuel delivery or fuel quality concerns, ignition or injector issues, MAF input, oxygen sensor circuits, or prior modifications. The key is not to guess. Work the path in order and let the fuel trims, pressure behavior, and sensor activity tell you where to go.

Start with the code check and captured conditions

Start by checking codes. For P0171, stay on the rich or lean fuel control path. If other codes are present outside that fuel-control group, check what those mean first instead of chasing fuel trim in isolation. Do not clear the codes and do not reset keep alive memory at this point. Go into the PCM data and record the ECT or ECT1 value from the captured conditions, because you want to recreate the operating condition that set the code.

Visual inspection before testing

With the ignition off, do a careful visual inspection before connecting test equipment. Check the air filter and air box for restriction. Inspect the intake tract from the MAF sensor to the intake manifold for leaks, loose connections, cracked tubes, damage, restrictions, and hoses that are out of place. Check the throttle plate for sludge or obstruction. Look over the vacuum hoses, vacuum tees, EVAP lines, intake manifold sealing, EGR leak points, PCV system integrity, and the correct PCV valve if equipped. Also inspect the exhaust for flange or gasket leaks, look over the oxygen sensor wiring and pins for damage or contamination, and make sure the dipstick, dipstick tube, and oil fill cap are seated correctly. If you find a vacuum leak, move to the vacuum leak repair verification. If you find another clear concern, repair it, clear the PCM codes, and repeat the self-test. If nothing shows up, keep going.

Power balance, then EVAP purge check

Next, run the Power Balance Test if the scan tool supports it. If that test is not available, follow the pass side of the decision. For P0171, a passing power balance sends you to the EVAP purge check. A failing power balance calls for a new fuel injector, then reset keep alive memory, clear the PCM codes, and repeat the self-test. For the EVAP check, use the scan tool canister purge valve check when it is available. If it is not available, close the purge command and vent command as directed, then watch FTP voltage. For this path, the EVAP check passes if the test passes, or if the FTP voltage stays within 0.5V of the recorded value within 30 seconds of closing the EVAP purge valve. If it fails, install a new EVAP canister purge valve, clear the PCM codes, and repeat the self-test. If it passes, go after a vacuum leak pattern with fuel trims.

Use fuel trims, then confirm MAP response if your path calls for it

Start the engine and monitor the temperature PIDs, intake air temperature, and short- and long-term fuel trims for both banks. Let the engine stabilize at the temperature needed to recreate the concern. If the captured ECT or ECT1 value is not available, use an engine temperature between 82°C - 101°C (180°F - 215°F), with the intake air temperature less than 46°C (115°F). Add long-term and short-term trim together for each bank at idle, then raise engine speed to 3,500 RPM for 10 seconds and calculate the same total correction again. For P0171, if the difference between idle and 3,500 RPM is less than 15 percent of the idle total, move on to fuel pressure testing. If the difference is not less than that, locate the vacuum leak. If your diagnostic path specifically brings you to a MAP voltage check, turn the ignition on, monitor MAP_V, record it key-on engine-off, start the engine, and record it running. For P0171, the MAP voltage needs to change; if it changes, continue to fuel pressure testing, and if it does not change, leave this path and diagnose the MAP concern.

Locate and verify a vacuum leak

To locate a vacuum leak, monitor SHRTFT1 and SHRTFT2 and restrict vacuum lines one at a time for 30 seconds. Do not clamp or pinch a hard plastic hose; use a vacuum cap or equivalent. If short-term fuel trim drops greater than 15 percent when a hose is restricted, you have found the direction of the leak and can verify the repair. If it does not, inspect the intake air system, intake manifold, and intake gaskets for a vacuum leak, repair as needed, then verify it. For verification, record short-term fuel trims before the repair, repair the leak, stabilize the engine again, and compare the trims. A decrease greater than 15 percent confirms the repair path. If the trim drop is not there, a vacuum leak is still present, so pause, recheck the earlier diagnostic path, and avoid guessing.

Oxygen sensor circuit check, fuel pressure, and FRP bias check

Some routes before fuel pressure include checking the UO2SPC circuit for an open. Only diagnose the suspect universal oxygen sensor. With the ignition off, disconnect the universal oxygen sensor connector and the PCM connector, then measure between C1661 Pin 3 and C175E Pin 51. The resistance should be less than 5 Ω. If it is not, repair the open circuit, reset keep alive memory, and repeat the self-test. Next, connect the universal oxygen sensor connector, relieve fuel pressure safely, connect a mechanical fuel pressure gauge, pressurize the system, start the engine, let pressure stabilize, and command the fuel pump to obtain maximum pressure. If pressure is not within range for the vehicle being diagnosed, leave this path and continue with fuel system diagnosis. If your path calls for a biased fuel rail pressure sensor check, turn the ignition off, disconnect the fuel injection pump connector, start the engine, monitor FRP, command FUEL_MASS_DI to maximum, and look for FRP between 345-827 kPa (50-120 PSI). If it is outside that range, the path calls for a new fuel rail pressure sensor, then clear the PCM codes and repeat the self-test.

Fuel pressure stability and the electrical noise branch

If fuel pressure is in range, check pressure stability. For fast leakdown, run the pump to maximum pressure, command the pump off, let pressure stabilize, record the reading, and watch it for 10 seconds. It should remain within 34 kPa (5 psi) of the recorded reading after 10 seconds. If it does not, inspect the tank, lines, and filler pipe for an external fuel leak. Repair any leak found, then verify. If no external leak is found on this P0171 path, continue with the fuel system leakdown diagnostic path. If fast leakdown passes, continue watching pressure for 1 minute. For slow leakdown, pressure should remain within 34 kPa (5 psi) of the recorded reading (MRFS) or greater than 275 kPa (40 psi) (ERFS) after 1 minute. If it fails, continue with the fuel system leakdown diagnostic path. If it passes, E100 vehicles move to the oxygen sensor and MAF checks; all others move to fuel quality and ethanol testing. On branches that point to electrical noise instead, turn the ignition off and inspect the CKP sensor harness for routing, alterations, incorrect shielding, or electrical interference. Also check for radio frequency interference and excessive audible generator noise. Repair any concern found, clear the PCM codes, and repeat the self-test. If no concern is present, move into a structured intermittent diagnostic approach.

Fuel quality and ethanol learning path

For the fuel sample check, use a 200 ml beaker, a 25 ml graduated cylinder, and clean water. Put 5 ml of clean water in the beaker. Drain 22 ml of fuel into an approved clean container, then pour 20 ml of that fuel into the 25 ml graduated cylinder. Add enough water to bring the total liquid volume to 24 ml, plug the cylinder, shake it to mix, then let it stand for approximately 3 minutes. Record the separation level where the ethanol-and-water layer meets the gasoline. If the mixture does not separate, treat the fuel as contaminated, replace the contaminated fuel, clear the PCM codes, and repeat the self-test. If it does separate, calculate ethanol percentage by taking the recorded separation level, subtracting the amount of water added, and multiplying the new value by 5. As an example, if the separation level is at 14 ml the calculation becomes; 14 minus 4, then multiply by 5 to equal 50. The percentage of ethanol in the fuel is 50%. If no ethanol is present, this P0171 path leaves fuel quality and continues with fuel system diagnosis. If ethanol is present on a flex fuel vehicle, compare FF_INF to the calculated ethanol percentage. FF_INF should be within 20% of the calculated percentage. For example, if the calculated percentage of ethanol value is 40% then the PID value should be between 32 - 48%. If FF_INF is within range, continue with fuel system diagnosis for P0171. If it is not within 20%, reset keep alive memory, start the engine, monitor FF_LRND, and drive approximately 11.3 km (7 miles), or until FF_LRND indicates yes. If it does indicate yes, cycle the ignition and compare the updated FF_INF again. The updated FF_INF also needs to be within 20% of the calculated percentage. If it is within range, the path ends with customer fueling guidance and using the same fuel for the next 2-3 refuels so the PCM can keep learning correctly. If it is still not within range, a fuel system concern may be preventing the PCM from learning the ethanol content, so continue with fuel system leakdown diagnosis. On a non-flex fuel vehicle, if calculated ethanol is less than 25%, this P0171 path continues with fuel system diagnosis. If it is not less than 25%, repair as necessary, advise the correct fuel type, reset keep alive memory, and repeat the self-test.

E100 path: oxygen sensor inspection, MAF check, and sensor activity

On the E100 branch after pressure stability passes, turn the ignition off, disconnect the universal oxygen sensor connector, and inspect for pinched, shorted, or corroded wiring and pins, oil or water contamination, crossed sensor wires, and a contaminated or damaged sensor. Repair any concern found, clear the PCM codes, and repeat the self-test. If the visual inspection is clean, check MAF function. Start the engine, monitor RPM, MAF voltage, and MAF frequency. Run the engine up to 1,500 RPM for 5 seconds, bring it back to idle, and repeat that once. At idle, the PID value needs to be within 30% of the normal value for the vehicle. If it is not, continue with MAF and IAT diagnosis. If it is, reconnect the oxygen sensor, get the engine into closed loop fuel control, and watch oxygen sensor current activity. For P0171, if the O2 current PID switches, the concern cannot be duplicated or identified at that moment, so move into a structured intermittent diagnostic approach. If it does not switch, install a new universal oxygen sensor, reset keep alive memory, clear the PCM codes, and repeat the self-test. On the rich-code branch, the next check is fuel leakage into the crankcase. Run the engine at normal operating temperature, record long- and short-term trims for both banks, turn the ignition off, disconnect the PCV line at the intake manifold, temporarily plug the intake manifold port, restart, and compare the new trims. If the trim shift shows the rich condition is gone, the path calls for a new fuel injection pump. If not, it calls for a new universal oxygen sensor. After either result, clear codes as directed and repeat the self-test.

Related oxygen sensor circuit branch

If the initial code check routes you into the heated oxygen sensor branch instead of the P0171 lean path, keep that branch separate. Start the engine, run it at approximately 2,000 RPM, and maintain that speed for 3 minutes while checking whether the oxygen sensor codes return. If they do return, diagnose the suspect sensor indicated by the code. With the ignition off, disconnect the PCM connector and the suspect sensor connector, then check the sensor harness for shorts between circuits. The resistances need to be greater than 10K ohms. If they are not, repair the short, clear the PCM codes, and repeat the self-test. If the harness passes that short check, check the oxygen sensor circuits for opens. The circuit resistances need to be less than 5 ohms. If they are not, repair the open, clear the PCM codes, and repeat the self-test. Next, with the ignition on, check for a short to voltage on the oxygen sensor circuit. If any voltage is present where it should not be, repair the short, clear the PCM codes, and repeat the self-test. If that passes, reconnect the PCM and oxygen sensor connectors, start the engine, let it idle for 2 minutes, and monitor the downstream oxygen sensor voltage PID for the suspect bank. If the PID voltage is less than 1.6 V, the concern cannot be duplicated at that moment, so move into a structured intermittent diagnostic approach. If it is not less than 1.6 V, the path calls for a new heated oxygen sensor, then reset keep alive memory and repeat the self-test.

Connector check, verification, and takeaway

If the ethanol relearn path sends you to a PCM operation check, disconnect the PCM connectors, inspect for pushed-out pins and corrosion, reconnect everything, make sure the connectors seat correctly, and verify whether the concern is still present. If it is still present, the path calls for a new PCM and programming. If it is gone, treat it as a loose or corroded connector issue. Keep verification separate from testing. After any branch that calls for a repair, follow the required reset or clear step for that branch, repeat the self-test, and confirm P0171 stays gone under the conditions that originally set it. The takeaway is simple: with P0171, prove air leaks first, then fuel pressure and leakdown, then fuel quality and sensor behavior. Do not replace parts just because the code says lean. For more diagnostic training, visit stepdiagnostics.com.

Final check

P0171 can have several possible causes, so the diagnosis should follow fuel trim behavior, pressure stability, fuel quality, and sensor activity instead of guessing at parts.

For more guided automotive diagnostics, visit STEP Diagnostics.

Continue diagnosing

Related guides for this vehicle