Well trajectory design and optimization are essential parts in well planning prior to drilling. The main objective of the design is to find an optimal trajectory for efficient and safe drilling. For instance, a designed well trajectory shall allow for maximum production from reservoirs and minimum tortuosity for successful casing running and completion. Fortunately, in well-explored geological areas, where stratigraphic sequences and corresponding geopressures are known, the main objective can be narrowed down to design a trajectory in consideration of reducing total drilling time, drilling cost or depth. Meanwhile, the anti-collision of well trajectory must be considered with offset wells in the same area. This paper presents a central part of plan phase represented by a trajectory planning and optimization module with a focus on anti-collision design. The trajectory is optimized based either on minimization of wellbore length and dogleg severity, on the maximization of well-reservoir contact subject to strict anti-collision constraint and other associated constraints or their combinations. The anti-collision model considers industry standard bit error sources and propagation along the well trajectory, and results in the separation factor as an constraint for trajectory optimization. The introduction of anti-collision models to the trajectory optimization techniques has real potential in drilling design. Besides saving time and effort by providing engineers, the well design with anti-collision considerations ensures the well path safety. The work has a good potential in well planning as a viable method to keep drilling operations' safe and efficient.