FAULTBASE
Error CodesASKCars
© 2026 FAULTBASE
All rights reserved.
v2.0.0 • Production
ContactPrivacyImpressum
how to replace the O2 sensor in my BMW 5 Series G30/G31 (2017-2024)? - BMW 5 Series
Home/Cars/BMW/5 Series/G30/G31 (2017-2024)/how to replace the O2 sensor in my BMW 5 Series G30/G31 (2017-2024)?

how to replace the O2 sensor in my BMW 5 Series G30/G31 (2017-2024)?

BMW 5 Series G30/G31 (2017-2024)

Error Codes
1-2 hours
Time
medium
Difficulty
medium
Severity
Navigation
ProblemSymptomsDiagnosisSolution
ProblemSymptomsDiagnosisSolution
3 min read
530 words

Problem Statement

The Oxygen (O2) sensor in your BMW 5 Series G30/G31 (2017-2024) requires replacement due to malfunction, which may lead to poor fuel efficiency and increased emissions.

Estimated Time
1-2 hours

⚠️ Safety Warnings

Important safety information - read before proceeding

  • •Disconnect the battery before working on electrical systems.
  • •Allow the exhaust system to cool before touching any components.

Symptoms

  • •Check engine light illuminated
  • •Decreased fuel economy
  • •Rough idle or stalling
  • •Failed emissions test
  • •Increased exhaust emissions
  • •Poor engine performance or hesitation

Diagnostic Steps

  1. 1
  2. 2
  3. 3
  4. 4
  5. 5

Solution

💡 Expert Tip

For complex repairs like this, consider taking photos at each step. This helps if you need to reverse a step or consult with a mechanic. Also, keep all removed parts organized - you may need to reference them during reassembly.

Verification

After completing the repair, verify that the issue has been resolved:

  • ✓Test the affected component to ensure it functions correctly
  • ✓Check for any error codes or warning lights
  • ✓Monitor the vehicle for a few days to ensure the issue does not recur

Prevention Tips

To prevent this issue from occurring again:

  • •Follow the manufacturer's recommended maintenance schedule
  • •Address warning signs early before they develop into major issues
  • •Use quality parts and fluids recommended for your vehicle
  • •Keep detailed records of all repairs and maintenance

Tools & Equipment Required

  • •Disconnect the negative battery terminal to avoid any electrical shorts.
  • •Raise the vehicle using a jack and secure with jack stands.

Parts Required

  • •New O2 sensor (upstream or downstream depending on replacement need)
  • •Anti-seize compound

Additional Information

Estimated Time
1-2 hours
Difficulty
medium
Severity
medium
Tools Required
2 items
Parts Required
2 items

Related Faults

Loading...

Share this solution

Comments

Sign in to share your thoughts

Sign In

No comments yet

Be the first to share your thoughts

Back to Generation
Solution
1. Preparation
  • Tools Required: Jack and jack stands, socket set, O2 sensor socket, torque wrench.
  • Disconnect the negative battery terminal to avoid any electrical shorts.
  • Raise the vehicle using a jack and secure with jack stands.
2. Locate the O2 Sensor
  • Identify whether you are replacing the upstream (pre-catalytic converter) or downstream (post-catalytic converter) O2 sensor.
  • The upstream sensor is typically located on the exhaust manifold or just before the catalytic converter, while the downstream sensor is located after the catalytic converter.
3. Remove the Old O2 Sensor
  • Using an O2 sensor socket, carefully loosen and remove the old O2 sensor by turning it counterclockwise.
  • If the sensor is stuck, apply penetrating oil and allow it to sit for a few minutes before attempting removal.
4. Install the New O2 Sensor
  • Apply anti-seize compound (if not pre-applied) to the threads of the new O2 sensor to prevent future seizing.
  • Install the new O2 sensor by threading it into the exhaust pipe and tightening it clockwise. Use a torque wrench to tighten it to the manufacturer's specifications (typically around 30-35 Nm, but verify with your service manual).
5. Reconnect Wiring and Battery
  • Connect the O2 sensor wiring harness back to the new sensor.
  • Reconnect the negative battery terminal.
6. Clear Error Codes and Test
  • Use the OBD-II scanner to clear any error codes.
  • Start the engine and allow it to reach operating temperature, ensuring the check engine light does not return.