This was never canonized scripture. It was a part of the Historical Appendix which has now been removed from the Doctrine and Covenants.
For many the assumption had always been that Joseph Smith III would suceede his father and there were even second hand accounts of Joseph Smith JR blessing his son, but there was no extant documentation to support this.
In February 1981 Mark Hofmann, a rare documents dealer, presented the LDS church with an extant version of this rumored documentation of Joseph Smith III’s designation as successor. The blessing came with a cover letter dated January 27, 1865 which was written by Thomas Bullock and chastised Brigham Young for having all of the copies of this blessing destroyed. This painted the LDS church and its previous leaders in a very bad light and Hofmann expected the LDS church would pay anything to obtain it and prevent it from becoming publicly known.
When the LDS church declined to buy it Hofmann approached the RLDS church, which they agreed to. Hofmann then used this as leverage to trade the document with the LDS church for items valued at over $20,000. The LDS church then traded the blessing with the RLDS church for a Book of Commandments.
In 1982 this blessing was added to the historical appendix of the Doctrine and Covenants through an action during World Conference. However, in 1986 this document was found to be a forgery created by Mark Hofmann. It was subsequently removed from the historical appendix via conference resolution #1204 in 1988.
A Blessing, given to Joseph Smith, 3rd., by his father, Joseph Smith, Junr., on Jany. 17. 1844.
Blessed of the Lord is my son Joseph, who is called the third, – for the Lord knows the integrity of his heart, and loves him, because of his faith, and righteous desires. And, for this cause, has the Lord raised him up; – that the promises made to the fathers might be fulfilled, even that the anointing of the progenitor shall be upon the heads of my son, and his seed after him, from generation to generation. For he shall be my successor to the presidency of the High Priesthood: a Seer, and a Revelator, and a Prophet, unto the Church; which appointment belongeth to him by blessing, and also by right.
Verily, thus saith the Lord: if he abides in me, his days shall be lengthened upon the earth, but, if he abides not in me, I, the Lord, will receive him, in an instant, unto myself.
When he is grown, he shall be a strength to his brethren, and a comfort to his mother. Angels will minister unto him, and he will be wafted as on eagle’s wings, and be as wise as serpents, even a multiplicity of blessings shall be his. Amen.