I think historically the pay has been higher for doctors because of:
a) probably a bit of hungover entrenched class privilege (plus a bit of sexism? Until relatively recently most doctors were men and most nurses women)
b) increased level of clinical responsibility - the scope for lethal mistakes as a doctor is larger than for a nurse because it includes misdiagnosis, wrong or omitted investigations and wrong or inappropriate instructions to other people, as well as drug errors and failing to appreciate / escalate serious illnesses / changes. In addition, doctors have and are still the person where the buck stops. As an example, as a junior SHO i used to manage a lot of (not pregnant) people with epidurals - one of the side effects is a low blood pressure. The nursing staff are told to contact anaesthetics if the blood pressure falls below a certain number. This is good, because for some people that can be harmful. Other people will tolerate a lower blood pressure just fine, and making it higher unnecessarily can cause other side effects and be harmful. Others again actually need their prescription reviewing to set a higher "trigger" to call, as they have different physiology. My job was to see the patient, assess them and make a judgement about what needed to happen. Do I think it was the hardest job in the world? No, of course not. A lot of it is experience, and knowing what to look for. Most of the senior nurses could probably have done it fine. But, they weren't. So it was my name in the notes and my responsibility for the judgement call.
c) increased levels of non-clinical responsibility including for teaching, audit, service development. The aim of training juniors to be consultants is for them to have ongoing responsibilities for all of these things (in varying amounts). The majority of nurses have not historically been expected to have these responsibilities. Nowadays some do, which they often do very well, and those who do have extended practice (whether teaching or independent prescribing) do have this reflected in their salaries (though not to the extent that perhaps they should - though many of the extended practice roles have relatively little out of hours work, which may be part of the discrepancy). The whole medical education system is essentially a giant Ponzi scheme, where you tell the more senior people they have to demonstrate ongoing involvement in teaching to pass their revalidation / appraisal and therefore they have to do it, but are rarely given any paid time to do this in.
I think there is a lot of blurring of roles in healthcare happening at the moment with advanced nursing practice, physicians associates etc etc developing new roles. I'm fairly ambivalent about this (far more than many of my colleagues), I think there are both good and bad things about it, but at the end of the day there will still need to be a group of people who have final responsibility for non-protocolised judgement calls and tbis will require considerable training and a salary to reflect the investment in training, the level of responsibility etc. Whether we'll be calling them doctors in 50 years time is another matter.
As an aside there was some discussion in 2007/8 about moving junior doctors onto the Agenda for Change payscale which nurses and most allied health professionals are on - it's supposed to reflect the particular skills and responsibilities of a post rather than the job title. It was abandoned because it was thought it would lead to increased Drs salaries.
Apologies for the stream of consciousness.