The 21-year-old will put pen to paper on a contract running until June 2015 at the Stadio San Paolo, subject to a medical.
A statement from Espanyol read: "RCD Espanyol and SSC Napoli have reached an agreement for defender Victor Ruiz to join the Italian team once he completes a medical in Naples on Friday.
"Ruiz will travel this afternoon (Thursday) to Italy and is expected to sign a four-and-a-half year contract with Napoli."
Ruiz has attracted plenty of interest from other top European clubs following some fine performances that have helped the Catalan club up to fifth in La Liga.
He will join fellow defender Lautaro Fernandez in arriving in the January transfer window. Fernandez signed from Argentine side Tigres earlier this month.
Follow live text commentary on these games this weekend: Hercules v Barcelona; Deportivo v Sevilla; Osasuna v Real Madrid; Espanyol v Villarreal
Follow live text commentary on these Italian games this week: Juventus v Roma; Lazio v Fiorentina; Catania v Milan; Inter v Palermo; Juventus v Udinese