All info on this official website. Click the icon that corresponds with your type of vehicle to bring up the obligatory testing intervals.
ITV test period will depend on the “Clasificacion del vehiculo” (C.L.)code on the Ficha Technica. Websearch will bring up a document that explains the codes. If classified as Turismo, then after 4 years up till 10 every 2 years, after 10 years old then every year. Otherwise vehicle generally follows the rules for commercial vehicle (includes many crossover ´mixto´ codes). Many vehicles can be re-classified for a fee by obtaining a certificate from the manufacturer and presenting that at the next ITV.
If in Andalucia, you can use the Veiasa App called ´ITV Andalucia´ to make an appointment. Available on Google Play and App Store.