How to Replace an Air Fuel Ratio Sensor

Air fuel ratio sensors, commonly known as a oxygen sensors, tend to fail within the driveability system of vehicles. When this sensor fails the engine will not perform optimally and can pollute the environment.

Usually an engine light will come on letting the operator know that something is not functioning properly. The indicator light that is associated with an air fuel ratio sensor will illuminate with an amber color.

Part 1 of 7: Identifying the malfunction indicator light

check engine light illuminated on the dash

When an engine light comes on, the first thing to do is scan the vehicle's computer for codes. Different codes may come on during the scan process letting you know that something within the engine caused the air fuel ratio sensor to fail.

The following are codes associated with the air fuel ratio sensor:

P0030, P0031, P0032, P0036, P0037, P0038, P0042, P0043, P0044, P0051, P0052, P0053, P0054, P0055, P0056, P0057, P0058, P0059, P0060, P0061, P0062, P0063, P0064, P0131, P0132.

The codes P0030 through P0064 will display that the air fuel ratio sensor heater has shorted or is open. For the codes P0131 and P0132 the air fuel ratio sensor has either a failed heater or there has been catastrophic failure due to thermal shock.

If you have scanned the vehicle’s computer and found different codes than mentioned, perform diagnostics and troubleshooting before replacing an air fuel ratio sensor.

Part 2 of 7: Preparing to replace the air fuel ratio sensor

Having all of the necessary tools and materials prior to starting the work will allow you to get the job done more efficiently.

Materials Needed

vehicle on level surface

Step 1: Park your vehicle on a flat, hard surface. Make sure that the transmission is in park (for automatics) or in 1st gear (for manuals).

Step 2: Place wheel chocks around the rear tires. Engage the parking brake to the lock the rear tires from moving.

Step 3: Install a nine volt battery saver into your cigarette lighter. This will keep your computer live and keep your setting current in the vehicle.

If you do not have a nine volt battery saver, that is fine.

Step 4: Open the vehicle's hood to disconnect your battery. Take the ground cable off of the battery’s negative post disabling the power to the air fuel ratio sensor.

  • Note: If you have a hybrid vehicle, use owner's manual for disconnecting the small battery only. Close the vehicle's hood.

jack lifting vehicle up

Step 5: Raise the vehicle. Using a floor jack, lift under the vehicle at its specified jacking points until the wheels are completely off the ground.

jack stand placed under vehicle

Step 6: Place the jack stands. Put the jack stands under the jacking locations and then lower the vehicle onto the jack stands.

For most modern cars, the jacking points will be on the pinch weld just under the doors along the bottom of the car.

  • Tip: It is best to follow the vehicle’s owner’s manual for proper jacking locations.

Part 3 of 7: Removing the air fuel ratio sensor

Materials Needed

air fuel ratio sensor location

Step 1: Get your tools and creeper. Go under the vehicle and locate where the air fuel ratio sensor is.

When identifying the location, determine if you need to remove the exhaust or a component to access the sensor using a socket.

If you have to remove the exhaust down to reach the sensor, then locate the closest mounting bolts to the front of the sensor.

Remove the butt connectors to the upstream sensor and downstream sensor. Remove the bolts to the exhaust and lower the exhaust to have access to the sensor.

  • Note: Keep in mind that the bolts may break due to rust and being seized on hard.

front drive shaft assembled

If the exhaust pipe goes around a drive shaft (front drive shaft for four wheel drive vehicles or rear drive shaft on all wheel drive vehicles) you will need to remove the drive shaft before lowering the exhaust pipe.

Remove the mounting bolts to the drive shaft and push in that section of the drive shaft into its slip yoke. If the drive shaft of the vehicle has a center support bearing, you will need to remove the bearing as well to lower the drive shaft.

If the vehicle is equipped with a engine guard, you will need to remove the guard to get to the exhaust pipe. Use the fastener remover to take off the plastic fasteners that hold the engine guard up. Lower the engine guard and place some where out of the sun.

Step 2: Disconnect the harness from the air fuel ratio sensor. Use your breaker bar and the air fuel ratio sensor socket and remove the sensor from the exhaust pipe.

Some air fuel ratio sensors may get stuck onto the exhaust pipe and make it almost impossible to remove. At this time, you would need to have a small portable torch handy.

Once you use the torch, use your breaker bar and the air fuel ratio sensor socket to remove the sensor from the exhaust pipe.

  • Note: Make sure that there is no flammable substance or fuel line near the exhaust pipe with using a portable torch. Use the portable torch and heat up the area around the mounting surface of the sensor.

  • Warning: Be careful where you put your hands as the surface on the exhaust pipe will be glowing red and very hot.

Step 3: Clean the harness to the vehicle using an electrical contact cleaner. After spraying the contacts, use a lint free cloth to wipe off any remaining debris.

Get the new sensor out of its box and clean the contacts with electrical contact cleaner to make sure that there is no debris on the contacts.

Part 4 of 7: Install the new air fuel ratio sensor

oxygen sensor being installed

Step 1: Thread the sensor into the exhaust pipe. Tighten the sensor up with your hands to finger tight.

Torque the sensor to the specifications that are provided on the slip in the bag or box that the sensor came with.

If for some reason there is no slip and you don’t know the specifications, you can tighten the sensor by 1/2 turn with metric 12 threads and 3/4 turn with metric 18 threads. If you do not know the thread size of your sensor, you can use a metric thread pitch gauge and measure the thread pitch.

Step 2: Connect the butt connector on air fuel ratio sensor to the vehicle harness. If there is a lock, make sure that the lock is in place.

If you had to reinstall the exhaust pipe, make sure that you use new exhaust bolts. Old bolts will be brittle and weak and cause them to break after some time.

Reconnect the exhaust up and torque the bolts to specifications. If you do not know the specifications, tighten the bolts to finger tight and 1/2 turn. You may need to tighten the bolts 1/4 turn more after the exhaust is hot.

If you had to reinstall the drive shaft, make sure that you tighten the bolts to factory settings. If the bolts are torque to yield, then you will need to replace them.

Reinstall the engine guard and use new plastic tabs to prevent the engine guard from falling off.

  • Note: Grease up the slip yoke and u-joint after installation (if there are grease zerks).

Part 5 of 7: Lowering the vehicle

Step 1: Raise the vehicle. Using a floor jack lift under the vehicle at its specified jacking points until the wheels are completely off the ground.

Step 2: Remove the jack stands. Keep them far away from the vehicle.

Step 3: Lower the vehicle to where all four wheels are on the ground. Pull out the jack and put it aside.

Step 4: Remove the wheel chocks. Set these aside.

Part 6 of 7: Hooking up the battery

mechanic hooking up battery cable

Step 1: Open the vehicle's hood. Reconnect the ground cable back onto the battery’s negative post.

Remove the nine volt battery saver from the cigarette lighter.

Step 2: Tighten the battery clamp. Ensure that the connection is good.

Part 7 of 7: Checking the engine

turning key in ignition

Step 1: Start and run engine. Remove the parking brake.

Move vehicle to a well-vented area and let the engine get to operating temperature.

  • Note: Keep in mind, the engine light may be still on.

  • Note: If you did not have a nine volt battery saver, your engine light will be off.

Step 2: Shut off engine. Let engine cool down for 10 minutes and restart.

You will need to perform this step nine more times if the engine light was off. This will reset your vehicle's computer in cycles.

Step 3: Test drive the vehicle. Drive the vehicle around the block about a mile or two to ensure that there are no leaks in your exhaust system.

It will take some time to make sure that the engine light will not come back on. You will have to drive your vehicle for 50 to 100 miles to verify if the engine light will come on again.

If the engine light comes back on after 50 to 100 miles, then there is another issue with vehicle. You will need to check the codes again and see if there is an indication of unforeseen problems.

The air fuel ratio sensor may need further inspection and diagnostics. There may be another underlying issue such as a fuel system issue or even a timing problem. If the problem persists, then you should seek out help from one of YourMechanic’s certified technicians to perform an inspection.

Next Step

Schedule Check Engine Light is on Inspection

The most popular service booked by readers of this article is Check Engine Light is on Inspection. Once the problem has been diagnosed, you will be provided with an upfront quote for the recommended fix and receive $20.00 off as a credit towards the repair. YourMechanic’s technicians bring the dealership to you by performing this job at your home or office 7-days a week between 7AM-9PM. We currently cover over 2,000 cities and have 100k+ 5-star reviews... LEARN MORE


The statements expressed above are only for informational purposes and should be independently verified. Please see our terms of service for more details

Recent Check Engine Light is on Inspection reviews

Excellent Rating


Rating Summary


40 years of experience
1080 reviews
40 years of experience
Plymouth Grand Voyager V6-3.3L - Check Engine Light is on - Lawrenceville, Georgia
Mr. Dan Barber was quite patient, courteous and quite knowledgeable. From my observation, Mr. Barber appears to be quite professional.
Nissan Altima - Check Engine Light is on - Gainesville, Georgia
Dan is a super nice man that listens to your issue and does an easy to understand explanation so that you can truly take in, process and actually feel like you know what is going on with your vehicle and needed repairs. Honesty is what I felt I received. He wanted to make sure I was in a safe operating vehicle. His skill and knowledge level are exceptional. I will never use another car dealership for diagnostics or repairs. Thank You Dan!!!!!


23 years of experience
624 reviews
23 years of experience
Toyota Camry L4-2.4L - Check Engine Light is on - Phoenix, Arizona
Attention to detail and provided clear information to his findings. Acted in a Profesional manner throuout
BMW X5 - Check Engine Light is on - Chandler, Arizona
Greg was running a bit late due to business being busy but he comunicated with me very well, and let me know where he currently was and what time to expect him. Also he went above and beyond by showing me some small things that I could do myself to make my older BMW run excellent. Thanks Greg, appreciate your passion for your job


8 years of experience
187 reviews
8 years of experience
Subaru Impreza H4-2.5L - Check Engine Light is on - Spanaway, Washington
Very professional courteous respectful knowledgeable explains everything of the aspect of work and what needs to be done on the vehicle. Exceptional awesome amazing friendly and kind. 10+stars. I highly recomend friends and families if they need a experience mechanic is to ho to your mechanic and ask for Keven. Thanks again for an exceptional diagnostic repairs on my daughter vehicle. Very happy and pleased.
Hyundai Veloster - Check Engine Light is on - Tacoma, Washington
He is very informative, professional and friendly. He told us what was wrong with our vehicle in details, and gave us very helpful suggestions.


19 years of experience
138 reviews
19 years of experience
Nissan Juke L4-1.6L Turbo - Check Engine Light is on - Hampton, Georgia
Professional, knowledgeable, diagnosed problem very quickly. Provided me with feedback as to probable cause of the defect.
Chevrolet Trax - Check Engine Light is on - Covington, Georgia
Very professional/punctual & knowledgeable. I’d prefer Brian to repair my moms vehicle since I’ve established a rapport with him if at all possible when I’ve gotten my final quote that’s reasonable after choosing services/parts to perform the repair work.

Need Help With Your Car?

Our certified mobile mechanics make house calls in over 2,000 U.S. cities. Fast, free online quotes for your car repair.


Related articles

P0391 OBD-II Trouble Code: Camshaft Position Sensor "B" Circuit Range/Performance (Bank 2)
P0391 code means indicates that the problem is on the side of the engine which does not contain cylinder #1 due to bad sensors, or connectors.
P0917 OBD-II Trouble Code: Gear Shift Position Circuit High
P0917 means there is an electrical malfunction with the gear shift position circuit, likely caused by damaged electrical components or broken wires.
P2080 OBD-II Trouble Code: Exhaust Gas Temperature Sensor Circ Range/Perf Bank 1 Sensor 1
P2080 means there is a malfunction in the circuit bank 1 sensor 1, likely due to an electrical component problem.

Related questions

Limp mode was on and I turned off the car. Now limp mode is off but the Check Engine Light is on.
When the car goes into limp mode, generally the reason for this is related to a critical component or sensor detecting a problem that may cause serious damage. There are existing codes in the computer which have been registered as...
Service engine light
The service engine light or check engine light coming on in cooler temperature could be you gas cap seal but you would need to have the computer scanned first to see if you have codes in memory of the computer...

How can we help?

Our service team is available 7 days a week, Monday - Friday from 6 AM to 5 PM PST, Saturday - Sunday 7 AM - 4 PM PST.

1 (855) 347-2779 ·