Police said a blue Toyota Corolla crashed while driving north on the B7024 High Maybole Road in Ayr at around 2.30pm on Friday.
The car appears to have lost control when approaching a left-hand bend, leaving the carriageway and crashing into the tree before coming to rest in a field.
The 31-year-old male driver and a 22-year old female rear seat passenger were found dead at the scene.
Three other male passengers, two aged 16 and one 34-year-old, were injured.
One of the teenagers was taken by air ambulance to the Queen Elizabeth University Hospital in Glasgow where his condition is said to be serious but stable.
The second teenager was taken to Crosshouse Hospital in Kilmarnock with serious injuries, but is in a stable condition.
The 34-year-old, who was the front seat passenger, is being treated at Ayr Hospital where his condition is also described as stable.
Sergeant Nicola Taylor, from the divisional road policing unit, Ayrshire, appealed for witnesses to the crash.
She said: “I would ask that anyone who was driving either on High Maybole Road, or in the immediate vicinity, who might have seen the car prior to the crash to contact police.”