Shape measurement of nonspherical microparticles by conventional methods such as optical microscopy is challenging owing to particle aggregation or uncertainty regarding the out-of-plane arrangement of particles. In this work, we propose a facile microfluidic method to align particles in-plane utilizing the extensional flow field generated in a cross-slot microchannel. Viscoelastic particle focusing is also harnessed to move particles toward the stagnation point of the cross-slot microchannel. We demonstrate that the shapes of ellipsoidal particles with various aspect ratios can be successfully measured using our novel microfluidic method. This method is expected to be useful in a wide range of applications such as shape measurement of nonspherical cells.