That is exactly what His Holiness, Pope Leo XIII did on June 11, 1899 in his Act of Consecration of the Human Race to the Sacred Heart of Jesus. He called this “the great act” of his pontificate.
The Holy Father presented his intentions to the Catholic world in the encyclical Annum Sacrum on May 25, 1899:
“But shall We allow to slip from Our remembrance those innumerable others upon whom the light of Christian truth has not yet shined? We hold the place of Him who came to save that which was lost, and who shed His blood for the salvation of the whole human race. And so We greatly desire to bring to the true life those who sit in the shadow of death. As we have already sent messengers of Christ over the earth to instruct them, so now, in pity for their lot with all Our soul we commend them, and as far as in us lies We consecrate them to the Sacred Heart of Jesus. In this way this act of devotion, which We recommend, will be a blessing to all.”
Then, on June 11, 1899, in communion with the bishops of the world, he prayed:
Most sweet Jesus, Redeemer of the human race . . . Be Thou King of all those who are still involved in the darkness of idolatry and Islamism, and refuse not to draw them all into the light and kingdom of God.