A technique based on the virtual source representation is presented for modeling head-related transfer functions (HRTFs). This method is motivated by the theory of simple layer potential and the principle of wave superposition. Using the virtual source representation, the HRTFs for a human head with pinnae are calculated with a minimal amount of computation. In the process, a special regularization scheme is required to calculate the equivalent strengths of virtual sources. To justify the proposed method, tests were carried out to compare the virtual source method with the boundary element method (BEM) and a direct HRTF measurement. The HRTFs obtained using the virtual source method agrees reasonably well in terms of frequency response, directional response, and impulse response with the other methods. From the numerical perspectives, the virtual source method obviates the singularity problem as commonly encountered in the BEM, and is less computationally demanding than the BEM in terms of computational time and memory storage. Subjective experiments are also conducted using the calculated and the measured HRTFs. The results reveal that the spatial characteristics of sound localization are satisfactorily reproduced as a human listener would naturally perceive by using the virtual source HRTFs.