Here's a quotation from "Some Alphabetical Notes," printed in the Typographical Journal 19(12), December 15th, 1901.
I and j were treated as one in dictionaries until after the first quarter of the nineteenth century, and in some cases this system is still carried on. The use of the j is said to have become general in English during the time of the Commonwealth, say between 1649 and 1658. From 1630 to 1646 its use was rare, and it is doubtful whether it was used prior to 1625. In the sixteenth century it became the fashion to tail the last i when Roman numerals were used, as in viij, for 8, or xij, for 12. An example from 1547 is as follows: "For j li of ffrangensence, iiijd." [That is, "for 1 pound of frankincense, 4 pence."]
What nation was the first to use it as a new letter is an interesting but perhaps unanswerable query. In France the use of j for the consonant and i for the vowel was, it is certain, established about the middle of the seventeenth century. Jacques Pelletier of Mans is said to have first placed j at the beginning of words with this consonant in his French grammar (1550), and his example was followed by a printer named Gille Beys, of Paris, in 1584. The confusion in English lasted until about seventy years ago [i.e. 1831].
In general what we're dealing with here is initial, medial, and final typographical forms of the same letter. You're probably aware that the Latin "s" has an initial/medial form ſ and a final form s. In some texts we see the initial form v and the medial/final form u, as in vniuersi for universi — although "Some Alphabetical Notes" indicates that things weren't terribly vniform in practice. (This is complicated by the fact that u upper-cases to V.) And in Roman numerals we see the initial/medial form i and the final form j.
"Some Alphabetical Notes" calls this an affectation peculiar to Roman numerals — but in fact we see the same final j all over the place in old Latin texts. I see "radij" (for "radii"), "vadij," "monarchij" — but also "radijs," "socijs," "petijt" (for "petiit"), indicating that it's not simply about the j appearing at the end of the word but something a little more like a digraph or ligature, where the last i in a run of two or more is turns into a j. See many examples in this catalog of books: Ambrosij, Amerbachij, Apollinarij, Frisij, Garcij, Ortelij, Pavij, aetij, alijs, principijs, euangelij, scholijs, etc., over a range at least as broad as 1537 to 1659.
But, as we saw above, the rule for Roman numerals, specifically, is that the last i in a run of any length (even a singleton) turns into a j.
(Note in passing that there are evolutionary relationships between ſs and German ß, between vv and w, and between Dutch ij and Afrikaans y.)
(Note that this all pertains to the Anglophone world, as far as I know; I don't know about other communities. In Spanish, where i could be a word in itself (modern y, "and"), there might have been good reason to write the number "1" as j instead of i; but I don't know if they ever did. Citations welcome.)