Multiphase flows, such as underwater explosions, rising bubbles, flooding of damaged cabins, etc., are widespread in nature and engineering. When conventional Eulerian mesh-based methods are adopted in the simulation of multiphase flows, some challenges are always encountered, including the large deformation and fragmentation of fluid, the capture of the multiphase interface, and so on. Therefore, many scholars turned their attention to meshless particle methods. As an important member of meshfree methods, smoothed particle hydrodynamics (SPH) was invented to solve astrophysical problems, and then it was applied to the simulation of hydrodynamics. In the SPH method, the computational domain is represented by a collection of particles whose properties, including density, velocity, internal energy, etc, are updated by the interaction between particles. Since the SPH method is free from the restriction of the mesh, it is good at handling large deformations of fluid. More importantly, the free-surface or multiphase interface does not need to be detected because the interface of the particles of different phases is also the interface of fluid. For these reasons, the SPH method has been widely used in the simulation of multiphase flows. Due to the natural Lagrangian characteristic of the SPH method, particles move strictly along streamlines, which may lead to uneven particle distributions and thus reducing the numerical accuracy in some cases. To solve this problem, some particle regularization schemes have been developed in the SPH method, in which the particle shifting algorithm is the most widely used one. The core idea of the shifting algorithm is to artificially move particles from a region with a high concentration of particles to a region with a low concentration of particles in each time step, thereby obtaining uniform particle distributions throughout simulations. In the published literature, there have been several multiphase models in the SPH method, and some of them adopt the particle shifting algorithm to make the discontinuous multiphase interface more stable and accurate. At present, the most commonly used shifting algorithm for multiphase flows is proposed by Mokos et al. When it is adopted, the moving material interface should be firstly detected. Then particles belonging to different phases are shifted by applying different treatments, aiming to avoid mutual mixing of different phase materials. These treatments are generally complicated and time-consuming, and sometimes they may result in unphysical gaps near the multiphase interface, reducing the numerical accuracy and stability. To tackle the problems mentioned above, a simpler and more accurate shifting algorithm is proposed in this paper. In this algorithm, the treatments applied to different fluids are consistent. Meanwhile, to ensure the clarity of the multiphase interface, the shifting magnitude of the particles near the interface is slightly increased. Compared with the shifting algorithm proposed by Mokos et al., the improved shifting algorithm is simpler and more efficient. More importantly, through the simulations of several classical multiphase problems in the SPH method, the proposed improved shifting algorithm is proved to be able to maintain perfectly uniform particle distributions near the interface even for long-term simulations, and thus the numerical accuracy and energy conservation are enhanced.