Later followed the First War of Castro, in which Francesco's Modena joined Venice and Florence and sided with the Dukes of Parma against Barberini Pope Urban VIII, aiming to reconquer Ferrara. The war ended without any particular gain for the Modenese. As again no help had come from Spain, Francesco allied with France through the intercession of Cardinal Mazarin. When he however failed to conquer Cremona, and as the situation of the Thirty Years' War seemed to be favourable for Spain, the Duke sought for an agreement with the latter. He returned to the service of France by marrying his son and heir Alfonso to Laura Martinozzi, Mazarin's niece.