During the winter months male humpback whales produce long complex sequences of sounds which have been described as song. Current hypotheses for the function of humpback whale song speculate that it serves primarily to provide other whales with information about the singer such as location and reproductive fitness. An alternative possibility, however, is that male humpback whales vocalize to obtain information about other whales through active acoustic interrogation of their environment. Specifically, it is proposed that the primary function of humpback whale song is as a long-range sonar used by males to locate other whales. The conclusions are based on (a) comparison of humpback signal types and patterns with those of other echolocating species; (b) application of the sonar equation to measured sound levels of humpback singers and target strengths of whales; and (c) humpback behaviors observed in association with singing. The complexity of humpback song in comparison to the vocalizations of bats and odontocetes is an adaptation to the long-range acoustical signal distortion caused by multipathing. Song phrases, in particular, are designed for echoic recognizability in the multipath environment.