Because a cactus grows so slowly, repotting should take place in early spring, when it comes out of dormancy. Repotting a dormant cactus may result in root loss, and the plant takes significantly longer to recover from repotting this way. If you live in a warm, frost-free climate where your cactus doesn't go dormant, it's typically fine to transplant cactus year-round.
Cactus needs well-draining medium usually with a sandy texture, especially on the top layers. Mix peat, perlite and coarse sand in equal parts for a thriving transplanted cactus. When transplanting the cactus, cover the bottom with the medium, then gently place the cactus in the center of the planter, and fill the pot with medium up to the previous soil line. Small stones placed on the topsoil give a decorative appearance.
Cactus does well in containers, with somewhat compacted roots. Potted cactus bloom more frequently, and so long as the roots aren't too compacted, they'll grow evenly. Choose a pot that is 1 inch larger in diameter than the current planter, or choose one that measures 2 inches larger around than the cactus. Because the growing media has fine grains, cover the planter's drain hole with a mesh screen or broken piece of clay pottery.
Cactus presents an injury risk that repotting other vegetation generally doesn't. Keep your hands needle-free by gently tying a thick rope or ribbon around the cactus, then using the rope as a handle to move the plant. You can also place a wide band of cardboard or rolled up newspaper around the width of the cactus. Barbecue tongs also work, but you must take care not to damage the cactus.