An IP address can be traced to a suburb or city. This is because IP addresses are assigned to ISPs (a country), who in turn generally allocate them to an exchange (a suburb or city).
Looking this up is done by using a database of known ISP/exchange mappings. It's not always accurate because a) ISPs and exchanges change all the time, which will change the mappings, b) ISPs may not allocate blocks of addresses to exchanges, c) some ISPs, eg AOL, re-route and proxy their customers all over the country, so you can't even be sure of the correct state, let alone city.
There are plenty of sites that will provide this "geo-locating" for free, eg DNSStuff, or you can pay for a service to use it in your own products eg Maxmind.
Getting a full, accurate physical address from an IP address requires linking the address with the billing address via the ISP, they will keep records of which customer was assigned which IP and when. But they won't give it out without a court order.