The AIM app for iPhones works pretty well -- if your friends are all on AOL's IM system. But a company called Palringo claims its new app will work with all of the major players:
Palringo integrates with several existing, popular instant messaging services: AOL's AIM, Google Talk, Yahoo! Messenger, Gadu Gadu, ICQ, Jabber and Windows Live Messenger. People can also use Palringo to contact their friends using iChat, Apple's instant messaging (IM) client.
I have yet to try it, but the earliest review I've seen is mostly positive.
Palringo is the true, multiservice IM application iPhone users were asking for after they were underwhelmed by the free AIM application, which only allowed users to chat with one service.
From my testing, the application freezes my iPhone every now and then, but practically all my downloaded apps are doing that anyway. We'll just have to hope the next firmware update will seal the cracks.