Planets with orbital periods shorter than 1 day are rare and have formation histories that are not completely understood. Small (R_p < 2 R_earth) ultra-short-period (USP) planets are highly irradiated, probably have rocky compositions with high bulk densities, and are often found in multi-planet systems. Additionally, USP planets found around small stars are excellent candidates for characterization using present-day instrumentation. Of the current full sample of approximately 5500 confirmed exoplanets, only 130 are USP planets and around 40 have mass and radius measurements. Wolf 327 (TOI-5747) is an M dwarf (Rstar=0.406+/-0.015R_{sun}, Mstar=0.405+/-0.019M{sun}, T_eff=3542+/-70K, and V=13mag) located at a distance d=28.5pc. NASA's planet hunter satellite, TESS, detected transits in this star with a period of 0.573d (13.7h) and with a transit depth of 818ppm. Ground-based follow-up photometry, high resolution imaging, and radial velocity (RV) measurements taken with the CARMENES spectrograph confirm the presence of this new USP planet. Wolf 327b is a super-Earth with a radius of Rp=1.24+/-0.06R_{Earth} and a mass of Mp=2.53+/-0.46M{Earth}_, yielding a bulk density of 7.24+/-1.66g/cm^3^ and thus suggesting a rocky composition. Owing to its close proximity to its host star (a=0.01au), Wolf 327b has an equilibrium temperature of 996+/-22K. This planet has a mass and radius similar to K2-229b, a planet with an inferred Mercury-like internal composition. Planet interior models suggest that Wolf 327b has a large iron core, a small rocky mantle, and a negligible (if any) H/He atmosphere.