A method for position sensing includes inserting a probe comprising at least one electrode into a body of a subject, and passing electrical currents through the body between the at least one electrode and a plurality of locations on a surface of the body. Respective characteristics of the currents passing through the plurality of the locations are measured in order to determine position coordinates of the probe.