This paper presents trajectory planning of a leg’s end-point position for a four-legged robot. A kinematic model of the leg is developed using the Denavit–Hartenberg (DH) method. The dynamic equation of motion is developed using the Euler–Lagrange formulation. Based on a mammal’s gait pattern, the leg’s trajectory is planned mathematically. Computer-Aided Design (CAD) model simulation is used to visualize the planned trajectory. The planned trajectory is tested for walking of a small four-legged robot working model. The working model of the robot is also tested for stable walking on different ground terrains and with maximum payloads.