Former Prime Minister Tun Dr Mahathir Mohamad is officially contesting the Langkawi parliamentary seat in the 14th General Election as a PKR candidate.