The interfacial energetics are known to play a crucial role in organic electronic devices. However, their effects in organic thermoelectrics remain to be elucidated. In this work we optimize the output power density of an organic thermoelectric generator (OTEG) at ambient atmosphere to record high values, by varying the work function of the metal contacts. We find that the effect is linked to extended gradients of doping states, which are induced by humidity and reside inside the organic layer oriented perpendicular to the metal contacts. The thermovoltage, arising from this contact phenomenon alone, reaches a magnitude similar to that of the Seebeck voltage of the conducting polymer itself, thereby providing a major contribution to the resulting thermoelectric performance. With this work, we put a new emphasis on the importance of the metal-polymer interface in thermoelectrics. The overall output performance can be greatly improved by fine-tuning the interfacial energetics, which then provides an attractive complementing route for enhancing the performance of OTEGs.