Khan edged the fight by scores of 114-113, 115-113 and 115-112 after being knocked down by the Mexican in round four.
Fighting in England for the first time in two years, Khan began confidently, peppering the veteran with a series of quick jabs.
In the third, though, Diaz showed that he was not there just to make up the numbers, catching Khan with a few good shots of his own before upping the ante again in the fourth round and knocking Khan over with a quick three-punch combination.
Khan recovered and regained his composure before dominating the fifth round with some slick counter-punching and began to catch Diaz with increasing ease as the fight went on.
The Mexican rallied again in the ninth and tenth before really putting Khan under pressure with two punishing right hooks that looked to stun the Bolton fighter in round 11.
With 30 seconds left of the fight, Khan was caught by a big shot yet again, but managed to evade the tiring Diaz and hang on until the final bell.