
What this code means
P0171 often indicates the engine controller may be correcting for a lean condition on bank 1.
What the vehicle may do
- The vehicle may idle rough.
- The vehicle may hesitate or feel weak under some conditions.
- The malfunction indicator lamp may be on.
- Fuel economy may change.
Possible fault areas
- Unmetered air or vacuum leaks may be involved.
- Air measurement or air induction issues may be involved.
- Fuel delivery, fuel quality, or injector issues can be possible areas.
- Exhaust, EVAP, or crankcase ventilation leaks may contribute.
- A mechanical engine condition may be possible if normal checks do not identify a cause.
Diagnostic path
Open on P0171
On this 2014–2018 GMC Sierra 1500 with the 5.3 gas engine, P0171 usually means the control module may be seeing a lean fuel trim condition on bank 1. The truck may idle rough, hesitate, feel down on power, or just turn the light on with no obvious complaint. Broadly, think possible unmetered air, air measurement errors, fuel delivery issues, exhaust leaks, EVAP or crankcase ventilation leaks, and, if the normal checks do not find anything, a possible mechanical engine condition. The goal is not to guess at parts. The goal is to prove why fuel trim is being driven lean.
How the fuel trim monitor is thinking
Before getting into the checks, remember what the system is trying to do. Ideal fuel trim values are around 0 %. With the engine running at operating temperature, normal short-term and long-term fuel trim should be between +10 and −10 %, with 0 % the optimum. The HO2S value should vary from approximately 40 mV to approximately 900 mV, and respond to fueling changes. For the monitor gates, the engine needs to be in closed loop, and the monitor should not be interrupted by catalyst, oxygen sensor, device-control, or EVAP leak routines. The engine coolant temperature is between −20 and +150°C (−4 and +302°F). The intake air temperature is between −20 and +150°C (−4 and +302°F). The manifold absolute pressure is between 10–255 kPa (1.5–37 psi). The engine speed is between 375–7,000 RPM. The mass air flow is between 1–510 g/s. The barometric pressure is greater than 70 kPa (10.2 psi), and the fuel level is greater than 10 %. Once those gates are met, the diagnostic runs continuously, and the code sets when the average long-term fuel trim weighted average is outside a calibrated value for approximately 3 min. On a P0171 path, unmetered air is a big concern, and a MAF condition can still be involved even when there is not a separate MAF code and the MAF numbers appear to be in range. Also do not overlook simple items: the correct air filter, oil fill cap tight, dipstick fully seated, and any aftermarket air filter, air induction, or exhaust changes that may affect the reading.
Start with the basic system checks
Start with the basic system checks, then follow a structured diagnostic approach and make sure you understand the diagnostic categories before you commit to one test path. With the ignition ON, first make sure there are no other codes that need to be handled. If other codes are present, check what they mean first instead of chasing fuel trim blind. If P0171 is not set right now, reproduce the operating conditions for the monitor, or reproduce the captured conditions from when the fault happened. If P0171 sets during that drive or run, move into circuit and system testing. If it does not set, the vehicle is passing this check at that time.
Testing starts with MAP plausibility, then fuel trim
For testing, turn the ignition ON and verify the MAP sensor pressure parameter is in the proper range for the vehicle’s altitude. If it is not, do not keep chasing P0171 yet; diagnose the MAP pressure issue first. If MAP pressure is plausible, run the engine at operating temperature and look at long-term fuel trim. The key split is whether Long Term Fuel Trim Bank 1 or 2 is between −10 % and +10 %, or whether it has moved beyond that range. For this P0171 episode, the important branch is the high positive trim branch.
If long-term trim is high positive
If Long Term Fuel Trim Bank 1 or 2 is greater than +10 %, turn the ignition OFF and inspect the lean-condition paths. Look for a skewed or contaminated MAF sensor; if short-term fuel trim on both banks changes greater than 20 % when the MAF sensor is disconnected, stop and diagnose the MAF performance problem. Check for contaminated fuel, missing, restricted, or leaking exhaust components, fuel injector problems, split or kinked vacuum hoses, and incorrect vacuum hose connections. Keep going through the air and sealing checks: insufficient fuel in the tank, low fuel pressure, a restricted or missing air filter element, anything altering airflow into the MAF, intake manifold leaks, throttle body leaks, injector O-ring leaks, air induction leaks, and air intake duct leaks. Also inspect the EVAP canister and evaporative pipes for cracking, obstruction, or leaks, and check the crankcase ventilation system for leaks. If you find one of those conditions, repair it as necessary. If none of those checks turns up a cause, inspect the engine for a mechanical condition.
If trim goes the other way
If Long Term Fuel Trim Bank 1 or 2 is less than −10 %, turn the ignition OFF and do not force a lean diagnosis. Work the rich-condition side instead. Inspect for fuel getting into the crankcase from the high pressure fuel pump, a skewed or contaminated MAF sensor, contaminated fuel, exhaust restrictions or leaks, injector problems, a collapsed or restricted air intake duct, excessive fuel pressure, a dirty or restricted air filter, objects blocking the throttle body, improper EVAP operation, and excessive fuel in the crankcase. If the short-term fuel trim on both banks changes greater than 20 % when the MAF sensor is disconnected, handle the MAF performance problem. If excessive fuel is found in the crankcase, change the engine oil as necessary. If you find a condition, repair it as necessary. If no condition is found, inspect the engine for a mechanical condition.
If trim is normal during the check
If Long Term Fuel Trim Bank 1 or 2 is between −10 % and +10 %, do not condemn anything from a normal snapshot. Operate the vehicle within the monitor’s operating conditions, or duplicate the captured conditions from when the fault occurred. If P0171 comes back, return to the listed inspection path and recheck it carefully. If it does not come back, the system is OK during that verification window.
Verify the repair
After the repair is complete, verify the repair and confirm the code stays gone. Then perform the scan tool Fuel Trim Reset. The takeaway is simple: for P0171, prove the fuel trim direction first, check MAP plausibility, then work the correct trim branch without jumping straight to parts. For more diagnostic training, visit stepdiagnostics.com.
Final check
Use fuel trim direction and operating-condition verification to guide the diagnosis before making any repair decision.
For more guided automotive diagnostics, visit STEP Diagnostics.





