The output power of any laser system is limited by the power that any of its individual components can withstand without being destroyed. This increases the size, complexity and cost of next-generation lasers built using conventional optical-gain media. But by using a plasma, which is impervious to optical damage, as the gain medium, such limitations could be significantly surpassed. Here, we report the use of stimulated Raman backscattering in a millimetre-scale plasma to simultaneously amplify and compress an input pulse to increase its intensity by more than two orders of magnitude. Further amplification and compression of such a pulse was achieved by passing it twice through our system, an approach that could be readily extended in future with a cavity-like multipass design. Such an approach could enable the construction of a new generation of compact, low-cost ultrahigh-intensity laser systems.