Flights from Santa Cruz de La Palma to Madrid generally leave from La Palma Airport and arrive in Madrid Barajas Airport.
La Palma Airport is 8.6 km away from Santa Cruz de La Palma city centre and Madrid Barajas Airport is 15.9 km from Madrid city centre.
Here are some other resources that might have the information you need