# P0171: System Too Lean (Bank 1)

**Verdict:** Drive to a shop this week

Fuel and air metering - Generic OBD-II code, applies to all gasoline cars and light trucks sold in the US since 1996.

- **Typical cost:** $15-$1,300
- **Urgency:** This week
- **Most likely:** Vacuum leak or dirty MAF sensor
- **DIY?:** Steps 1-3

## Quick answer

P0171 means the engine on bank 1 is getting too much air or too little fuel, and the computer has reached its limit trying to add fuel to correct it. A vacuum leak is the most common cause, followed by a dirty MAF sensor and weak fuel delivery.

## What does P0171 mean?

The engine computer aims to burn fuel and air at a precise ratio. It measures incoming air with the MAF or manifold pressure sensor, injects fuel to match, then checks the result with the upstream oxygen sensor. Small corrections, called fuel trims, are added or removed constantly. Short-term trim reacts instantly, and long-term trim learns a lasting correction that is stored in memory.

P0171 sets when bank 1 needs so much extra fuel that the total trim reaches the computer's limit, often somewhere around +20 to +25 percent depending on the maker, for a set time. The fuel system monitor runs much of the time the engine is warm, and the code usually needs the fault on two trips. "Lean" means too much air or too little fuel. Bank 1 is the side with cylinder 1, and on most inline engines it is the whole engine. The matching bank 2 code is P0174.

## What are the symptoms of P0171?

- Check engine light on
- Rough idle, sometimes with a hissing sound from the engine bay
- Hesitation or stumbling when accelerating
- Misfires, especially at idle
- Hard starting or stalling

## What causes P0171?

Ranked from most to least likely. Check them in this order: the cheap, common causes first.

1. **Vacuum leak** (most common). Cracked vacuum hoses, a split PCV hose, a leaking intake manifold gasket or a leaking brake booster let in air the computer never measured. Rubber and plastic parts harden and crack with age and heat, so higher-mileage engines are most at risk. Fuel trims that are high at idle but improve at higher RPM point strongly to a vacuum leak.
2. **Dirty or failing MAF sensor** (common). A MAF sensor coated with dust or oil under-reports airflow, so the computer adds too little fuel and trims climb to compensate. It often follows an over-oiled aftermarket filter or a poorly sealed air box. Unlike a vacuum leak, trims that stay high or get worse at higher RPM and under load point to the MAF.
3. **Weak fuel pump or clogged fuel filter** (less common). Low fuel pressure starves the engine, especially under load when demand peaks. A weak in-tank pump, a clogged filter or a faulty pressure regulator can cause it, and high-mileage vehicles are most affected. A fuel pressure and volume test confirms it, and trims that rise during acceleration or hill climbing are a clue.
4. **Clogged or dirty fuel injectors** (less common). Varnish and deposits slowly narrow injector nozzles, so less fuel is sprayed and the spray pattern worsens. It is more likely on high-mileage engines and cars that sit unused for long periods. A partly clogged injector often goes with a misfire code on one cylinder. A shop can balance-test or flow-test the injectors.
5. **Exhaust leak before the upstream oxygen sensor** (less common). Outside air pulled into the exhaust ahead of the upstream oxygen sensor makes the sensor read lean, so the computer adds fuel the engine does not actually need. Cracked manifolds, broken studs and leaking flange gaskets are typical, especially in road-salt states. A ticking sound on cold start that fades when warm is a common sign.

## How do you diagnose P0171?

1. Read short-term and long-term fuel trims at idle and at about 2,500 RPM; total trims above about +10 to +15 percent confirm a lean condition.
2. Listen for hissing and inspect vacuum hoses, the PCV hose and intake boots for cracks.
3. Have a shop smoke-test the intake to find hidden leaks.
4. Clean the MAF sensor and compare its reading with the expected airflow for your engine.
5. Test fuel pressure and volume if the trims are worst under load.

## How do you fix P0171, and what does it cost?

| Fix | Typical cost | What it involves |
| --- | --- | --- |
| Clean the MAF sensor | $15-$100 | Cheap first step when trims rise with RPM. |
| Repair a vacuum leak (hose, PCV valve or gasket) | $100-$600 | Hoses are cheap; intake manifold gaskets cost more because of labor. |
| Replace the fuel pump or fuel filter | $150-$1,300 | Only after a pressure test shows weak fuel delivery. |

Full price breakdowns: [mass air flow sensor replacement cost](/cost/mass-air-flow-sensor-replacement).

## Is it safe to drive with P0171?

> **Drive to a shop this week.** It is usually safe to drive short distances, but a lean engine can misfire, overheat its catalytic converter and, under heavy load, damage pistons. Fix it within a week or two.

## Will P0171 fail an emissions test?

P0171 keeps the check engine light on, which fails an OBD-II emissions test in most states. A lean engine may also misfire and raise emissions. After the repair, clearing the code resets the readiness monitors and stored fuel trims, so drive several days of mixed trips to let the monitors finish and trims relearn before testing.

## After the repair: clearing P0171

Clear the code, or reset fuel trims with a scan tool, after the repair. At warm idle and at about 2,500 RPM, total fuel trim should now be close to zero, often within about plus or minus 10 percent. Drive several mixed trips so long-term trim relearns. No pending code and stable trims mean the fix worked.

## How to prevent P0171

- Inspect vacuum and PCV hoses for cracks at every oil change, especially on older engines.
- Clean the MAF sensor with proper spray if mileage drops or the idle gets rough.
- Replace fuel filters on schedule and avoid running the tank nearly empty.
- Keep the air box sealed so unmetered air cannot slip in after the MAF sensor.
- Repair exhaust leaks ahead of the oxygen sensor so it reads the true mixture.

## P0171 by make

| Make | What to know |
| --- | --- |
| Ford | Many Ford V6 and V8 engines set P0171 together with P0174 from cracked PCV hoses or leaking intake manifold gaskets. |

## Codes often seen with P0171

- [P0174](/codes/p0174): System Too Lean (Bank 2)
- [P0101](/codes/p0101): Mass or Volume Air Flow "A" Circuit Range/Performance
- [P0300](/codes/p0300): Random/Multiple Cylinder Misfire Detected
- [P0087](/codes/p0087): Fuel Rail/System Pressure - Too Low
- [P0172](/codes/p0172): System Too Rich (Bank 1)

## Frequently asked questions

### What is the most common cause of P0171?

A vacuum leak is the most common cause of P0171. Cracked hoses, a split PCV hose and leaking intake gaskets let in unmetered air. A dirty MAF sensor is the next most likely cause, followed by weak fuel delivery. A smoke test finds most leaks quickly, so it is worth paying for before replacing parts.

### Can I drive with a P0171 code?

Yes, for short trips, but do not ignore it. A lean engine runs hotter and can misfire, which can damage the catalytic converter, and severe lean running under heavy load can harm pistons. Have it diagnosed within a week or two, and avoid towing or hard acceleration in the meantime.

### Why do I have both P0171 and P0174?

When both banks are lean, the cause is usually something they share, like a vacuum leak at the intake manifold, a dirty MAF sensor or low fuel pressure. A single clogged injector or an exhaust leak near one bank is less likely, because it would normally affect only that side of the engine.

### How much does it cost to fix P0171?

Most P0171 repairs cost $15-$1,300. MAF cleaner is about $15, while a shop cleaning runs up to $100. Vacuum leak repairs range from $100 for a hose to around $600 for an intake gasket, and a fuel pump or filter runs $150-$1,300. A smoke test is usually a modest diagnostic charge.

### Can I fix P0171 myself?

Partly. Listening for hissing, inspecting hoses, cleaning the MAF sensor and reading fuel trims with a scan tool are all doable at home, and replacing a cracked hose is often easy. Smoke testing, fuel pressure testing and intake gasket work are usually better left to a shop with the right equipment.

### What are fuel trims?

Fuel trims are the percentage the computer adds to or removes from its base fuel amount to hit the right mixture. Positive numbers mean it is adding fuel because the engine looks lean. Short-term trim changes constantly; long-term trim is the learned correction. High positive long-term trim on bank 1 is what sets P0171.

### Can a bad oxygen sensor cause P0171?

Less often than people think. The upstream oxygen sensor usually reports lean correctly because the engine really is lean. A sensor biased lean, or an exhaust leak ahead of it, can cause P0171, but test for vacuum leaks, MAF problems and fuel pressure before replacing an oxygen sensor.

### Can P0171 cause a misfire?

Yes. A very lean mixture is harder to ignite, so P0171 often appears with misfire codes such as P0300, especially at idle. Fixing the lean condition usually stops the misfires. If misfires remain after the trims return to normal, check the spark plugs, coils and that cylinder's injector.

### Why did P0171 appear after an air filter change?

It can happen if the air box lid is not fully sealed, the intake boot was knocked loose or the MAF connector was not fully plugged in. Air that bypasses the MAF sensor makes the engine run lean. Recheck every clip, clamp and connector you touched before looking for other causes.

### Can a loose gas cap cause P0171?

No, a loose gas cap does not cause P0171; it sets evaporative system codes such as P0455 or P0457 instead. A faulty EVAP purge valve can upset the mixture, though it more often makes the engine run rich. For P0171, focus on vacuum leaks, the MAF sensor and fuel delivery.

## Sources

- [SAE J2012: Diagnostic Trouble Code Definitions](https://www.sae.org/standards/content/j2012_201812/)
- [EPA: On-Board Diagnostics (OBD)](https://www.epa.gov/state-and-local-transportation/vehicle-emissions-board-diagnostics-obd)

## Other fuel and air metering codes

- [P0151 O2 Sensor Circuit Low Voltage (Bank 2 Sensor 1)](https://diagxcar.com/codes/p0151)
- [P0153 O2 Sensor Circuit Slow Response (Bank 2 Sensor 1)](https://diagxcar.com/codes/p0153)
- [P0155 O2 Sensor Heater Circuit (Bank 2 Sensor 1)](https://diagxcar.com/codes/p0155)
- [P0156 O2 Sensor Circuit (Bank 2 Sensor 2)](https://diagxcar.com/codes/p0156)
- [P0157 O2 Sensor Circuit Low Voltage (Bank 2 Sensor 2)](https://diagxcar.com/codes/p0157)
- [P0158 O2 Sensor Circuit High Voltage (Bank 2 Sensor 2)](https://diagxcar.com/codes/p0158)
- [P0161 O2 Sensor Heater Circuit (Bank 2 Sensor 2)](https://diagxcar.com/codes/p0161)
- [P0172 System Too Rich (Bank 1)](https://diagxcar.com/codes/p0172)
- [P0174 System Too Lean (Bank 2)](https://diagxcar.com/codes/p0174)
- [P0175 System Too Rich (Bank 2)](https://diagxcar.com/codes/p0175)
- [P0087 Fuel Rail/System Pressure - Too Low](https://diagxcar.com/codes/p0087)
- [P0101 Mass or Volume Air Flow "A" Circuit Range/Performance](https://diagxcar.com/codes/p0101)
- [P0102 Mass or Volume Air Flow "A" Circuit Low](https://diagxcar.com/codes/p0102)
- [P0106 Manifold Absolute Pressure/Barometric Pressure Circuit Range/Performance](https://diagxcar.com/codes/p0106)

## Symptoms

- [Why is my car idling rough?](https://diagxcar.com/symptoms/rough-idle)
- [Why does my car hesitate when I accelerate?](https://diagxcar.com/symptoms/car-hesitates-when-accelerating)
- [Why does my car stall while driving?](https://diagxcar.com/symptoms/car-stalls-while-driving)
- [Why does my car jerk when I accelerate?](https://diagxcar.com/symptoms/car-jerks-when-accelerating)
- [Why does my car lose power when accelerating?](https://diagxcar.com/symptoms/car-loses-power-when-accelerating)
- [Why does my car shake at idle?](https://diagxcar.com/symptoms/car-shakes-at-idle)
- [Why is my car getting bad gas mileage?](https://diagxcar.com/symptoms/poor-gas-mileage)

## Repair costs

- [Mass air flow sensor replacement cost](https://diagxcar.com/cost/mass-air-flow-sensor-replacement): $150-$450
- [Exhaust manifold gasket replacement cost](https://diagxcar.com/cost/exhaust-manifold-gasket-replacement)
- [Fuel injector replacement cost](https://diagxcar.com/cost/fuel-injector-replacement)
- [Fuel pump replacement cost](https://diagxcar.com/cost/fuel-pump-replacement)
- [Oxygen sensor replacement cost](https://diagxcar.com/cost/oxygen-sensor-replacement)

## Warning lights linked to this

- [Check engine light](https://diagxcar.com/warning-lights/check-engine)

## Terms explained

- [What is DTC?](https://diagxcar.com/glossary/dtc)
- [What is Fuel trim?](https://diagxcar.com/glossary/fuel-trim)
- [What is Mass air flow sensor?](https://diagxcar.com/glossary/mass-air-flow-sensor)

---

Source page: https://diagxcar.com/codes/p0171
Updated: 2026-11-03
General information, not a substitute for a qualified mechanic.
