P0171 — System Too Lean Bank 1
P0171 means the engine is running too lean on bank 1 — too much air or too little fuel — and the computer has reached the limit of how much extra fuel it can add to compensate.
Severity: Medium · Can you keep driving? Short trips are usually fine, but do not ignore it — a lean engine runs hot and can damage the catalytic converter.
What the P0171 code means
The engine computer constantly trims the fuel mixture using the oxygen sensors. When it has to add much more fuel than normal to keep the mixture right — typically long-term fuel trim above roughly +20 to +25 percent — it gives up and sets P0171: system too lean, bank 1.
Lean means the cylinders are getting too much air, too little fuel, or a sensor is misreporting one of the two. The extra air usually sneaks in after the mass airflow sensor, so the computer never measured it and never added fuel for it. That is why vacuum leaks top the cause list, and why the code is most common on older cars with hardened hoses and gaskets.
Fuel trim data tells you where to look before you touch a part. If trim is high at idle but improves as revs rise, air is leaking in — the leak is a bigger fraction of total airflow at idle. If trim stays high at speed and under load, suspect fuel delivery or the airflow sensor: the engine is being starved in proportion to demand.
Symptoms of P0171
- Rough idle, sometimes with the engine stumbling or stalling at stops
- Hesitation or stumbling when you press the accelerator
- Loss of power, especially at highway speed or under load
- Hard starting, particularly when cold
- Misfire codes (P0300–P0304) stored alongside
- Worse fuel economy despite the 'lean' label, as the computer over-fuels to compensate
- A hissing sound from a split vacuum hose in some cases
What causes P0171?
- Vacuum leak — cracked hoses, a failed PCV valve or hose, leaking intake manifold gaskets, or a leaking brake booster let unmetered air in after the airflow sensor. The most common cause, especially when the code is worse at idle.
- Dirty or faulty mass airflow (MAF) sensor — a contaminated sensing element under-reports incoming air, so the computer under-fuels. Cleaning helps when the element is merely dirty; a failed sensor must be replaced.
- Low fuel pressure — a weak fuel pump, clogged fuel filter, or faulty pressure regulator starves the injectors. Suspect this when trim is high under load rather than at idle.
- Dirty or leaking fuel injectors — clogged injectors deliver less fuel than commanded; a leaking injector seal also admits air at the intake port.
- Exhaust leak ahead of the oxygen sensor — a crack or gasket leak before the upstream sensor draws in outside air and makes the computer think the mixture is lean when it is not.
- Faulty upstream oxygen sensor — a sensor stuck reading lean drives the computer to keep adding fuel. Less common than leaks, and should be proven by comparing its signal with fuel trims before replacement.
How serious is P0171?
A mildly lean engine is not an emergency, but lean running is not harmless. Combustion temperatures rise, which stresses valves, pistons, and the catalytic converter, and a vacuum leak big enough to set this code often gets worse until the car stalls at idle or will not start cleanly.
Short, gentle trips while you book a diagnosis are reasonable. Sustained highway driving or towing with a known lean condition is not — get it fixed first, especially if misfire codes are present.
How much does it cost to fix P0171?
The spread of possible causes makes the range wide, so the cheapest step is diagnosis with fuel-trim data. Typical US costs for the common fixes, parts and labor:
| Repair | Typical US cost (parts & labor) |
|---|---|
| MAF sensor cleaning or PCV hose/valve replacement | $50–$250 |
| Intake gasket or vacuum hose repair | $150–$500 |
| Mass airflow sensor replacement | $200–$450 |
| Fuel pump replacement | $600–$1,100 |
| Fuel injector service or replacement | $300–$900 |
Prices are typical US ranges and vary by vehicle, location, and shop. Diagnosis usually costs $100–$150 and is often applied to the repair bill if you proceed at the same shop.
How P0171 is diagnosed and fixed
- Read fuel trims with a scan tool. Note short- and long-term trim on bank 1 at idle, then at a steady 2,500 rpm. High at idle and falling with revs points to a vacuum leak; high everywhere points to fuel delivery or the MAF sensor.
- Inspect vacuum hoses, the PCV system, intake boots, and manifold gaskets. A smoke test of the intake system finds leaks quickly and removes the guesswork.
- Clean the MAF sensor element with proper MAF cleaner and recheck trims; test sensor output against specification if the code returns.
- Measure fuel pressure with a gauge, at idle and under load, and compare with the manufacturer's specification. Low pressure leads to the pump, filter, or regulator.
- Check for exhaust leaks ahead of the upstream oxygen sensor and verify the sensor's switching behavior on a graph.
- Repair the cause, clear codes, and road-test while watching long-term trim return toward single digits.
Frequently asked questions
What causes a P0171 code?
Most often a vacuum leak — a split hose, bad PCV valve, or leaking intake gasket letting in air the computer never measured. Dirty or faulty mass airflow sensors and low fuel pressure from a weak pump or clogged filter are the next most common causes.
How much does it cost to fix P0171?
Anywhere from about $50 for a hose or PCV valve to $600–$1,100 for a fuel pump. A MAF sensor typically runs $200–$450 fitted and intake gasket work $150–$500. Fuel-trim diagnosis first usually keeps the bill at the lower end. Prices vary by vehicle, location, and shop.
Can I drive with P0171?
Short trips are usually OK, but do not put it off. A lean engine runs hotter than it should, may hesitate or stall, and can overheat the catalytic converter over time. Avoid towing and sustained high-load driving until it is repaired.
Is P0171 a serious code?
It is a medium-priority fault. It rarely strands you on day one, but the causes — vacuum leaks, failing fuel pumps, bad sensors — get worse, not better, and the extra heat and poor running can damage the catalytic converter, which is far more expensive than most of the causes.
Can a dirty air filter cause P0171?
Almost never. A clogged filter restricts air, which tends to make the mixture richer, not leaner. If someone suggests the filter first, ask to see the fuel-trim numbers — a vacuum leak or weak fuel delivery is far more likely.
Related codes
More in this system: Powertrain codes · Full codes list