Bilbao set up a showpiece clash on Sunday against Real Madrid, who beat Barcelona on Wednesday.
After a slow-paced first period in Riyadh's half-empty King Fahd stadium the teams woke up when Atletico went ahead just past the hour with an own goal by Bilbao keeper Unai Simon.
Lemar's corner from the right was met by the head of Joao Felix whose effort struck the post only for the ball to hit the back of the diving Simon and cross the line.
Bilbao equalised with another header from a corner as Yeray Alvarez found the net from close range in the 77th minute.
They then piled the pressure on Atletico, whose goalkeeper Jan Oblak made three glorious saves.
But even the outstanding Oblak could not keep out Williams' low shot from a rebound on edge of the area that went in off the post in the 81st to secure the victory.