What a camshaft position sensor does and why it fails

Your camshaft position sensor tells your engine's computer where the camshaft is in its rotation cycle. The computer uses this information to time fuel injection and spark plug firing correctly. When the sensor fails, your engine light comes on, your car may run rough or stall, and fuel economy drops.

Sensors fail because they get hot, get wet, or straightforward wear out after years of vibration. Most last between 80,000 and 150,000 miles, though some go longer. A failed sensor is one of the most common reasons for a check engine light, and it is one of the repairs you can often do yourself if you have basic tools and some patience.

Key Takeaways

  • The camshaft position sensor is usually bolted to the cylinder head or valve cover and takes five to thirty minutes to remove, depending on your car's layout.
  • You will need a socket wrench, a screwdriver, and possibly a sensor socket (a specialty tool that costs $10 to $20), plus a new sensor and gasket or O-ring.
  • Before you start, disconnect the negative battery terminal to prevent electrical shorts, and let the engine cool if it has been running.
  • The sensor connector unplugs first, then the mounting bolt comes out, and the old sensor slides free — installation reverses these steps.
  • After installation, clear the check engine code with a scanner or by disconnecting the battery for fifteen minutes, then test-drive to confirm the light stays off.

Locate your sensor and gather the right tools

Your camshaft position sensor is mounted on or near the cylinder head, usually close to the top of the engine. On some cars it sits on the driver's side, on others the passenger's side, and on some engines with dual overhead cams you may have two sensors — one for each cam. Check your owner's manual or a repair manual for your specific year and model to find the exact location before you start.

Gather these tools before you begin: a socket set (usually 8mm, 10mm, or 13mm depending on your car), a screwdriver (Phillips or flat-head), a new sensor with its gasket or O-ring, and a sensor socket if your sensor sits in a tight spot where a regular socket will not fit. A sensor socket is a hollow socket with a slot cut in the side so the wiring harness can pass through — it costs $10 to $20 at any auto parts store and makes removal much easier on some vehicles. You may also want a gasket scraper to clean the old gasket off the mounting surface.

Disconnect the battery and unplug the sensor

Turn off the engine and let it cool for at least ten minutes if it has been running. Open the hood and locate the negative battery terminal — it is the black wire attached to the negative post on your battery. Loosen the nut holding the cable to the post and slide the cable off. This prevents electrical shorts while you work.

Find the electrical connector on your camshaft position sensor. It is usually a plastic plug with a clip or tab. Press or slide the clip to release it, then pull the connector straight out. Some connectors are tight — wiggle gently rather than yanking. If the connector does not budge, check that you have released the clip fully.

Remove the mounting bolt and slide the sensor out

Locate the single bolt that holds the sensor to the cylinder head or valve cover. It is usually 8mm, 10mm, or 13mm. If you have a sensor socket, install it on your ratchet and fit it over the sensor body — the slot in the socket lets the wiring pass through. If you do not have a sensor socket, use a regular socket that fits the bolt head snugly.

Turn the ratchet counterclockwise to loosen the bolt. Once it is loose enough, you can usually finish unscrewing it by hand. Set the bolt aside in a safe place — you will reuse it. Gently wiggle the sensor side to side and pull it straight out of its hole. It may take a little pressure; do not force it, but do not be afraid to pull firmly. Once it is free, inspect the rubber O-ring or gasket on the sensor body. If it stayed in the hole, you will need to remove it before installing the new sensor.

Clean the mounting surface and install the new sensor

Look inside the hole where the sensor sat. You will see either a rubber O-ring still in place or old gasket material. If an O-ring is stuck in the hole, use a small screwdriver or pick to pry it out gently. If gasket material is crusted on, use a gasket scraper or old credit card to scrape it clean. Wipe the hole with a clean rag to remove any debris or oil.

Take your new sensor and check that it comes with a new O-ring or gasket. If it does not, you need to transfer the O-ring from the old sensor or buy one separately — do not reuse the old one. Slide the new sensor into the hole, aligning it so the bolt hole lines up. Insert the mounting bolt by hand first and turn it a few times to make sure the threads are catching correctly. Then use your socket and ratchet to tighten it snugly — do not over-tighten, as you can crack the sensor body. A firm hand-tight plus a quarter turn is usually enough.

Reconnect the electrical connector and battery

Plug the electrical connector back onto the sensor. You should hear or feel a click as the clip locks into place. Tug gently on the connector to make sure it is seated fully. Then reconnect the negative battery cable by sliding it back onto the negative post and tightening the nut. Do not over-tighten — snug is enough.

Start the engine and let it idle for a minute. The check engine light may still be on at this point; that is normal. You will clear the code in the next step.

Clear the check engine code and test the repair

The check engine light will stay on until you clear the fault code from the engine computer. You have two options. The first is to use an OBD-II scanner, which you can buy for $25 to $50 or borrow from an auto parts store. Plug the scanner into the diagnostic port under the steering wheel, follow the on-screen prompts to read and clear the code, and the light should go out.

The second option is to disconnect the negative battery cable again and leave it disconnected for fifteen minutes. This drains the computer's memory and clears the code. Reconnect the cable, start the engine, and the light should be gone. This method works on most cars but not all — if the light comes back on when ready, use a scanner instead.

Take the car for a test drive of at least ten minutes at highway speed. The engine should run smoothly, idle steadily, and feel normal. If the check engine light comes back on, the sensor may be defective, the connector may not be seated fully, or there may be a second problem. Recheck the connector first, then consider having the code read again to see if it is the same sensor code or something different.

Frequently Asked Questions

How much does a camshaft position sensor cost?

A new sensor typically costs $30 to $100 depending on your car's make and model. OEM (original equipment manufacturer) sensors are more expensive than aftermarket ones, but both usually work well. Labor at a shop runs $150 to $300, so doing it yourself saves most of that cost.

Can I drive with a bad camshaft position sensor?

You can drive short distances, but the engine will run poorly — it may stall, hesitate, or use more fuel. Driving long distances risks stalling in traffic or on the highway. It is better to replace it as soon as you can, especially if you are seeing the check engine light.

What if the new sensor does not fix the check engine light?

First, recheck that the connector is fully seated and the bolt is tight. If the light is still on, use a scanner to read the code again. It may be a different code, which points to a separate problem like a wiring issue or a bad connector. If it is the same sensor code, the new sensor may be defective and you should return it.

Do I need to replace the gasket or O-ring every time?

Yes. The old gasket or O-ring loses its seal after being compressed and heated. Reusing it risks oil leaks and sensor failure. Most new sensors come with a fresh gasket or O-ring, but check before you buy to make sure.

Is there a difference between a camshaft position sensor and a crankshaft position sensor?

Yes — they are different sensors in different locations. The crankshaft sensor is usually lower on the engine and tells the computer where the crankshaft is. The camshaft sensor is higher up and tells the computer where the camshaft is. Both can fail independently, and both cause check engine lights. Your scanner will tell you which one is bad.