A crystallographic indexing algorithm,pinkIndexer, is presented for the analysisof snapshot diffraction patterns. It can be used in a variety of contexts includingmeasurements made with a monochromatic radiation source, a polychromaticsource or with radiation of very short wavelength. As such, the algorithm isparticularly suited to automated data processing for two emerging measurementtechniques for macromolecular structure determination: serial pink-beam X-raycrystallography and serial electron crystallography, which until now lackedreliable programs for analyzing many individual diffraction patterns fromcrystals of uncorrelated orientation. The algorithm requires approximateknowledge of the unit-cell parameters of the crystal, but not the wavelengthsassociated with each Bragg spot. The use ofpinkIndexeris demonstrated byobtaining 1005 lattices from a published pink-beam serial crystallography dataset that had previously yielded 140 indexed lattices. Additionally, in tests onexperimental serial crystallography diffraction data recorded with quasi-monochromatic X-rays and with electrons the algorithm indexed more patternsthan other programs tested.