OBD-II diagnostic trouble code
P0340Caution

Camshaft Position Sensor Circuit Malfunction

The camshaft position sensor tells the computer which stroke each cylinder is on, which is what allows sequential fuel injection and correct ignition timing. Unlike a crankshaft sensor failure, many engines can still limp along without a good camshaft signal, just running worse.

Symptoms

  • Hard starting, especially a longer crank time before the engine catches
  • Rough idle and reduced power
  • Occasional stalling, though usually less abrupt than a crankshaft sensor failure
  • Reduced fuel economy

Likely causes

  • Failed camshaft position sensor — the most common cause
  • Damaged or corroded wiring or connector at the sensor
  • Timing chain/belt wear that's thrown the camshaft slightly out of its expected position
  • Oil-fouled sensor tip on engines where the sensor sits close to moving parts

How to diagnose it

  1. Inspect the sensor connector and wiring for corrosion or damage first
  2. Test the sensor signal with a scan tool while cranking or idling
  3. If timing-chain wear is suspected (rattling noise on startup), check timing marks/chain stretch before condemning the sensor

Typical fixes & cost

  • Replace the camshaft position sensor70250 EUR
  • Repair wiring or connector60200 EUR
  • Timing chain/belt service, if that's the underlying cause4001200 EUR

Related codes

Get an OBD-II scanner to read codes yourself →
Code names are compiled from open/standardized SAE and ISO references. Explanations, symptoms, causes and fixes are original. Covers generic (P0/C0/B0/U0) codes only — manufacturer-specific codes are planned for a future update.

Frequently asked questions

Can I drive with P0340?

You can usually keep driving with P0340, but don't put it off — the underlying cause can get worse or lead to further damage the longer it goes unaddressed. Get it diagnosed as soon as you reasonably can.

How much does it cost to fix P0340?

obd_lookup.code_faq_cost_answer

What causes P0340?

Failed camshaft position sensor — the most common cause Damaged or corroded wiring or connector at the sensor Timing chain/belt wear that's thrown the camshaft slightly out of its expected position
AS
Reviewed by Artyom SemenovAutomotive Editor · Fact-checked by Yauheni Kapliarchuk, Editor-in-Chief
Code names compiled from open SAE/ISO references; explanations and repair guidance are original editorial content
Last verified: 09 Jul 2026 · Our methodology