# What does an oxygen sensor do?

## Quick answer

An oxygen sensor, or O2 sensor, measures how much oxygen is in the exhaust so the engine computer can keep the fuel mixture right.

## What is Oxygen sensor?

Oxygen sensors screw into the exhaust pipe. Most cars have at least two: an upstream sensor before the catalytic converter and a downstream sensor after it. Engines with two cylinder banks often have four. Scan tools label them by bank and position, so bank 1 sensor 1 is the upstream sensor on the side with cylinder 1, and sensor 2 is downstream.

The upstream sensor tells the computer whether the engine is running rich (too much fuel) or lean (too little). The computer uses that reading to adjust fuel all the time. The downstream sensor mainly checks how well the catalytic converter is working. A working converter smooths out the oxygen level, so the downstream signal should stay fairly steady.

Older and many downstream sensors are narrowband types that switch quickly between rich and lean readings. Many newer cars use a wideband sensor, often called an air-fuel ratio sensor, upstream, which reports exactly how rich or lean the mixture is. Each sensor has a built-in heater so it works soon after a cold start.

Sensors wear out slowly over many miles. Oil burning, coolant leaks and some fuel additives can contaminate them sooner. A failing one can cause poor fuel economy, a rough idle and codes such as P0131, P0133 or P0135. Exhaust leaks near a sensor can also cause false readings.

## How it works

1. The sensor tip sits in the exhaust and compares the oxygen in the exhaust with the outside air.
2. It sends a changing voltage or signal to the engine computer.
3. The computer adds or removes fuel to keep the mixture close to ideal.
4. A built-in heater warms the sensor quickly so it works soon after a cold start.

## Types of Oxygen sensor

| Type | What it is |
| --- | --- |
| Upstream sensor (sensor 1) | Before the catalytic converter; its reading is used to control the fuel mixture. |
| Downstream sensor (sensor 2) | After the catalytic converter; mainly used to check how well the converter is working. |
| Narrowband sensor | A switching-type sensor that reports rich or lean; common downstream and on older cars. |
| Wideband air-fuel ratio sensor | Used upstream on many newer cars; reports the exact mixture rather than just rich or lean. |

## Common Oxygen sensor problems

- A slow or lazy sensor response that causes P0133 and lower fuel economy.
- A failed internal heater, setting codes such as P0135 or P0141.
- Contamination from oil, coolant or silicone that makes readings inaccurate.
- Damaged wiring or connectors from exhaust heat or road debris.
- False readings from an exhaust leak near the sensor that lets outside air in.

## Frequently asked questions

### What are the symptoms of a bad oxygen sensor?

Common signs are a check engine light, lower fuel economy and a rough idle. Some cars hesitate or smell of fuel, and some fail an emissions test. A bad downstream sensor often causes only a code, such as P0420 or a sensor circuit code, with no noticeable drivability change.

### What is the difference between upstream and downstream O2 sensors?

The upstream sensor is before the catalytic converter and helps control the fuel mixture. The downstream sensor is after the converter and mainly checks how well the converter works. They are often different part numbers, so make sure you buy the right one for the position.

### Can a bad oxygen sensor cause a P0420 code?

Yes, it can. A slow or faulty downstream sensor can make a good converter look bad, so the sensors are often checked before replacing the converter. An exhaust leak near a sensor or an engine problem can also cause P0420, so a full diagnosis saves money.

### How long do oxygen sensors last?

Many modern oxygen sensors last a long time, often 100,000 miles or more, though older designs wore out sooner. Some makers list a replacement interval, so check your owner's manual. Oil burning, coolant leaks and rich running can shorten sensor life.

### How much does it cost to replace an oxygen sensor?

At an independent shop, oxygen sensor replacement often costs about $150 to $450 per sensor, and dealers often charge $300 to $600. Upstream wideband sensors usually cost more than downstream sensors. Seized sensors that are hard to remove can add labor.

### Can I replace an oxygen sensor myself?

Often yes, with an oxygen sensor socket and some penetrating oil. Sensors can be very tight from heat and rust, so working on a slightly warm exhaust can help, but be careful of burns. Use anti-seize only if the new sensor does not come with it already applied.

### What does bank 1 sensor 2 mean?

Bank 1 is the side of the engine with cylinder number 1, and sensor 2 is the downstream sensor after the catalytic converter. So bank 1 sensor 2 is the rear sensor on that side. Four-cylinder engines usually have only bank 1.

### Does a bad O2 sensor hurt gas mileage?

It can. If the upstream sensor reports the wrong mixture or responds slowly, the computer may add more fuel than needed, lowering fuel economy. A faulty downstream sensor usually has less effect on mileage, since it mainly monitors the converter.

### Can I clean an oxygen sensor?

Cleaning is not usually recommended. Deposits on the sensor tip are hard to remove without damaging it, and a contaminated sensor often has an underlying cause such as oil burning. If testing shows a sensor is bad, replacement is the reliable fix.

### What is an air-fuel ratio sensor?

An air-fuel ratio sensor is a wideband type of oxygen sensor used upstream on many newer cars. It measures exactly how rich or lean the mixture is, instead of just switching between rich and lean. It is usually more expensive than a standard narrowband sensor.

## Sources

- [EPA: On-Board Diagnostics (OBD)](https://www.epa.gov/state-and-local-transportation/vehicle-emissions-board-diagnostics-obd)
- [fueleconomy.gov: Keeping your vehicle in shape](https://www.fueleconomy.gov/feg/maintain.jsp)

## Related terms

- [Catalytic converter](https://diagxcar.com/glossary/catalytic-converter)
- [Fuel trim](https://diagxcar.com/glossary/fuel-trim)
- [Mass air flow sensor](https://diagxcar.com/glossary/mass-air-flow-sensor)
- [OBD-II](https://diagxcar.com/glossary/obd-ii)

## Related pages

- [P0133 O2 Sensor Circuit Slow Response (Bank 1 Sensor 1)](https://diagxcar.com/codes/p0133)
- [P0135 O2 Sensor Heater Circuit (Bank 1 Sensor 1)](https://diagxcar.com/codes/p0135)
- [P0141 O2 Sensor Heater Circuit (Bank 1 Sensor 2)](https://diagxcar.com/codes/p0141)
- [Oxygen sensor replacement cost](https://diagxcar.com/cost/oxygen-sensor-replacement): $150-$450

---

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