Submicron sized sensors could allow higher resolution in X-ray imaging and diffraction measurements, which are ubiquitous for materials science and medicine. We present electrical measurements of a single 100 nm diameter InP nanowire transistor exposed to hard X-rays. The X-ray induced conductance is over 5 orders of magnitude larger than expected from reported data for X-ray absorption and carrier lifetimes. Time-resolved measurements show very long characteristic lifetimes on the order of seconds, tentatively attributed to long-lived traps, which give a strong amplification effect. As a proof of concept, we use the nanowire to directly image an X-ray nanofocus with submicron resolution.