Star trails occur when the movement of stars across the night sky causes their images to stretch across multiple pixels in a long exposure photograph. The "500 rule" or "600 rule" can help photographers calculate the maximum shutter speed to avoid star trails based on their camera's focal length. For example, with an APS-C camera using an 11mm lens, the maximum shutter speed to avoid trails would be 28 seconds, calculated by dividing 500 by the full frame equivalent focal length. This rule provides a starting point, but individual results may vary and require testing shutter speeds.