Resistive random access memories (Re-RAMs) have transpired as a foremost candidate among emerging nonvolatile memory technologies with a potential to bridge the gap between the traditional volatile and fast dynamic RAMs and the nonvolatile and slow FLASH memories. Here, we report electrochemical metallization (ECM) Re-RAMs based on high-density three-dimensional halide perovskite nanowires (NWs) array as the switching layer clubbed between silver and aluminum contacts. NW Re-RAMs made of three types of methyl ammonium lead halide perovskites (MAPbX 3 ; X = Cl, Br, I) have been explored. A trade-off between device switching speed and retention time was intriguingly found. Ultrafast switching speed (200 ps) for monocrystalline MAPbI 3 and ~7 × 10 9 s ultralong extrapolated retention time for polycrystalline MAPbCl 3 NW devices were obtained. Further, first-principles calculation revealed that Ag diffusion energy barrier increases when lattice size shrinks from MAPbI 3 to MAPbCl 3 , culminating in the trade-off between the device switching speed and retention time.