Polyaniline is a model molecular system in the study of conductive polymers. Ionic liquids, on the other hand, are becoming more and more a very convenient alternative for conventional organic solvents. The dissolution of polyaniline‐emeraldine base (PANI‐EB) in imidazolium ILs leads to its doping, as indicated by optical and resonance Raman spectroscopies. In this study, it is proposed that the interaction of PANI‐EB and imidazolium ILs involves the specific interaction of the quinoid moiety of the former with the imidazolium ring of the latter, an interpretation that is also based on N K‐edge XANES measurements of neat PANI‐EB, neat ILs, and of their solutions.