 Born in 1776, Ricafort was the son of José Ricafort y Abarca, Advocate of the Royal Council, and Juana Palacín y Aysa, a member of a noble family in Huesca.He was baptized at the Cathedral of Huesca and was later made regidor of the town for life.In 1793, he enlisted in the military and served as an infantry cadet during the campaign in Roussillon.