P0017 Mercedes Code: Crankshaft and Camshaft Timing Mismatch
7 min read · by Nicole Bennett · Last updated: November 25, 2026
The p0017 Mercedes code means the engine computer sees the crankshaft and camshaft position signals out of step with each other. It sets when those signals do not match what the computer expects for that engine.
The code is a generic OBD-II code, but the sensors, wiring and repair steps differ by model and engine. Use this guide to read the code and plan your checks, then confirm the fix with Mercedes service information for your exact vehicle.
What the P0017 code means
P0017 is a generic OBD-II code for crankshaft position and camshaft position correlation on Bank 1, Sensor B. The wording is standard, but the sources checked for this guide do not agree on every detail.
OBD-II trouble codes begin with a letter and a digit. According to Wikipedia’s on-board diagnostics article, a second character of 0 marks a generic code defined by SAE, so P0017 is not a Mercedes-only code.
Bank 1 is the side of the engine that contains cylinder 1. Sensor B is the second position sensor on that bank, so the code compares two signals rather than pointing to one confirmed failed part.
The sources do not match on the exact sensor name. One iATN technician summary lists the same code as a crankshaft and camshaft timing misalignment on Bank 1 Sensor 2, and it notes that the definition varies by vehicle. Confirm the exact definition in your Mercedes service data before ordering parts. The same code can behave differently on other vehicles, so it helps to compare it with P0017 Subaru Code.

What the computer is checking
The engine computer compares the crankshaft position signal with the camshaft position signal and sets P0017 when the two no longer agree within its expected range.
Crankshaft position tells the computer where the pistons are. Camshaft position tells it when the valves open and close. When those two signals drift apart, the computer cannot confirm that valve timing matches engine position, so it stores the code.
A mismatch can come from the sensor signal, the wiring that carries it, or the timing relationship between the crankshaft and camshaft. The scan data is what tells you which of these to check first.
The code does not name a single failed part. That is why the first job is to read the live data, not to replace a sensor.
Symptoms you may notice
The clearest case in the sources is a car that runs normally while the check engine light comes on and off.
According to an iATN technician mail summary from 2009, a 2006 Mercedes-Benz ML350 set this code. The owner said the engine ran fine, but the malfunction light came on and off. The post had no replies, so treat it as one owner report, not a diagnosis.
The sources checked for this guide do not list other symptoms, such as rough idle, hesitation or stalling, as confirmed signs of this code. Do not assume your car matches a symptom list until the scan data supports it.
Stop driving if the engine runs rough, stalls, loses power, or the warning light flashes. A timing fault can affect how the engine runs under load, so have the car towed or inspected in that case. Compare the causes listed here with P0017 Kia to rule out make-specific issues.

How to check P0017 with a scanner
A scan tool with live data is the fastest way to see whether the crankshaft and camshaft signals disagree. Save your notes before you clear anything, because the first reading is the most useful record.
- Record the freeze frame data, including engine speed, engine load and coolant temperature, to see the conditions when the code set.
- Check for other codes, especially other camshaft, crankshaft or misfire codes, which can point to the same area.
- Watch the crankshaft and camshaft position data side by side at idle, then under a light load, and note whether the two signals move together.
- Check the oil level and condition, a basic step before any timing work.
- Clear the code only after your notes are saved, then see whether it returns after a drive cycle.
A code that returns quickly points to a fault that is still active. A code that stays away may have been intermittent, but that does not rule out a timing fault, so keep the freeze frame notes for the shop. It is also worth reading P0010 Mercedes Code for the same vehicle.
Causes to check first
The sources checked for this guide do not give a ranked list of causes for Mercedes engines, so the list below is a general approach, not a confirmed diagnosis.
- Sensor and wiring: connector condition, damaged wiring, and a signal that drops out in the live data.
- Timing components: wear or stretch in the timing drive, which can shift the relationship between crankshaft and camshaft.
- Camshaft adjusting hardware: the parts that change cam position, checked against the procedure for your model.
- Oil supply: oil level and condition, since oil feeds the camshaft adjusting hardware on many engines.
A common mistake is swapping a sensor before reading the live data. A sensor replacement costs money and does nothing if the timing relationship is the real fault. For another common fault on this model, see P0011 mercedes Diagnosis.
Repair cost and when to see a shop
No fixed price applies, because repair cost depends on which part is at fault and the labor rate in your area.
Timing work usually costs more than a sensor replacement because it involves more labor and more parts. Quotes vary by shop, so check local pricing before you approve work.
Ask the shop to show the freeze frame, the live data, and the exact procedure from service information for your model before you approve parts.
When this is not a DIY job
Timing work belongs with a qualified technician, because a wrong install can damage the engine. Timing components control valve movement, and on some engines an error during timing work can bend valves or cause other internal damage.
Check the engine type in your service information before any hands-on work. If the engine runs rough, the light flashes, or power drops, stop driving and get a qualified shop to inspect the car. If you need equipment for this job, see Best OBD2 App for iPhone.
Frequently Asked Questions
What does a p0017 Mercedes code mean?
It means the crankshaft and Bank 1 camshaft position signals do not match what the engine computer expects. The code is generic in structure, but the sensor location and repair steps depend on the model and engine, so check your exact vehicle before buying parts.
Can I keep driving with a P0017 code?
If the engine runs rough, stalls or the light flashes, stop driving. If it runs normally with a steady light, get a scan soon, because the sources checked do not set a safe mileage limit for this code and a timing fault can get worse over time.
Is P0017 the same on every Mercedes?
The code definition is standard, but sensor locations, timing parts and procedures change by model year and engine. Confirm the fix against Mercedes service information for your exact car before you start work.
Will clearing the code fix the problem?
No. Clearing the code only resets the light. If the crankshaft and camshaft signals still disagree, the code returns, so the underlying fault must be found and corrected first.
Before buying parts, confirm the sensor, timing parts and procedure for your exact Mercedes model. Keep the scan data and freeze frame notes so the shop can see what you found, because a clear diagnosis prevents an expensive wrong repair.
-
Nicole Bennett, Technical Content Editor at BestOBD2Picks Nicole turns OBD-II standards, service bulletins, and repair data into step-by-step diagnostic guides anyone can follow. Technical Content Editor
Related guides
LearnP0010 Mercedes Code: Meaning, Oil Wicking Causes, and Diagnostic Steps
LearnP0016 Mercedes Code: Timing Meaning and Safe Checks
LearnP0021 Mercedes Code: Causes, Symptoms, and Diagnostic Steps
LearnP0050 Mercedes: Find the Oxygen Sensor Heater Fault and Fix It
LearnP0037 Mercedes: Diagnose the Oxygen Sensor Heater Fault
LearnP0159 Acura: Diagnose Bank 2 Sensor 2 Correctly