A private health insurance policy with full coverage in Spain, no copays, no waiting periods, and no maximum reimbursement limits. Public insurance (such as your home country's) is not accepted.
Buy from a Spanish insurer that issues a 'certificado para extranjería' — common picks are Sanitas (Más Salud or similar full-coverage plans), Swisscare Student Insurance, Adeslas, DKV, or Mapfre. Ask explicitly for the immigration certificate; a generic policy summary will be rejected.