As the diminutive of dad formed with -y, daddy emerged in the sixteenth century as a child-like way to refer to one's father. The Oxford English Dictionary under "daddy, n." gives a first attested usage from John Skelton:
1523 J. Skelton Goodly Garlande of Laurell sig. Dii/2 By saynt mary my lady your mammy and your dady Brought forth a godely babi.
And the next quote explains the child-centered context of its usage:
1552 R. Huloet Abcedarium Anglico Latinum Dadde or daddy, as infantes cal their fathers.
Over the next couple of centuries, usage applied more widely to figurative fathers, people older or in a position of management, domesticated slaves, and musicians:
(from def. 1b) 1682 J. Phillips Conf. Observator & Heraclitus 12 He opposes the Priviledges of his Enthusiastick Parliament, to the Royalties of Holy Daddy.
(from def. 1c) 1886 Graphic 10 Apr. 399/2 The manager himself is sometimes known as the ‘gorger’, and ‘daddy’ is the stage-manager.
(from def. 2a) 1837 Southern Literary Messenger Dec. 744/1 These [domestics] too were greeted always by the kind appellatives of ‘daddy and mammy’—and ‘uncle and aunt’;—and I have even now living, a jet black ‘daddy’ and two ‘uncles’.
(from def. 2a) 1948 New Yorker 3 July 28 The bebop people have a language of their own. They call each other Pops, Daddy, and Dick.
By the early 20th century, daddy was used to refer to a male partner in a heterosexual relationship. It appeared to come first from African-American usage (early usages are from sheet music, suggesting they were first recorded as blues and jazz lyrics), after which it entered wider usage:
- b. U.S. (in early use chiefly in African-American usage). A woman's male lover; a husband. Frequently as a form of address. Cf. papa n.2 2a, sugar daddy n. at sugar n. Compounds 3a.
1919 P. Bradford I'm Crazy 'bout your Lovin' (sheet music) 2 I've got a lovin daddy Who cert'nly can love sweet.
1999 J. Ridley Everybody smokes in Hell 129 I'm touching myself, Daddy. Are you touching yourself?
The OED then identifies the first application to a homosexual partner as "Prison slang":
- Prison slang. A man who takes an active or dominant role in a homosexual relationship, esp. one who provides physical protection to a (typically younger) more vulnerable inmate.
1933 V. F. Nelson Prison Days & Nights vi. 150 The active participants [in homosexual intercourse]..who are known as ‘wolves’, ‘jockers’, ‘daddies’, etc., are generally looked upon with comparative respect.
It distinguishes this from general applications to homosexual relationships, which appear by the end of the next decade:
- Among gay men: a masculine older man; spec. one who is romantically or sexually interested in younger partners, sometimes with the implication that such a man will play a more (sexually) active or dominant role (cf. sense 4).With quot. 1949, cf. sense 2b.
The first quote makes a direct connection to heterosexual usage, suggesting that the application of daddy to dominant homosexual male partners was an extension of applying it to dominant heterosexual male partners:
[1949 ‘Swasarnt Nerf’ in H. Hagius Gay Guides for 1949 (2010) 58 The following words..are frequently used..in a sense..equivalent to, their meaning in straight English (slang)... Bitch..daddy..faggot
1.]
In short, daddy acquired a transferred sense of referring to older men or male figures. One sense was applied to male lovers of women; by the 1930s and 1940s this was most likely transferred to male lovers of men.
1 I condemn using faggot in a derogative sense, and only use this example because it is important to the answer.