In 2002, Castillo unsuccessfully ran for mayor of Anguía with the centre-left party Possible Peru of Alejandro Toledo.[1][31] He served as a leading member of the party in Cajamarca from 2005 until the party's dissolution in 2017 following its poor results in the 2016 general election.[12][32] Following his leadership during the teachers' strike, numerous political parties in Peru approached Castillo to promote him as a congressional candidate, though he refused and instead decided to run for president after being encouraged by unions.[4]