The Royal Palace in Madrid is a 5-minute walk from the Opera metro station. From the Airport, take Line 8 to Nuevos Ministerios and then change to line 10 and get off Plaza de Espana station. You will see the Royal Palace after 5 minutes.
Alternatively, people coming from the centre, around the Plaza Mayor, can follow Calle Mayor directly to the palace and you they will find themselves at its doors in less than fifteen minutes.
Calle de Bailen, s/n 28071 Madrid, Spain