Harness 3D routing is one of the most challenging steps in the design of aircraft Electrical Wiring Interconnection System (EWIS). This is due not only to the intrinsic complexity of the EWIS, but also to the increasing number of applying design constraints and its dependency on any change in the design of the airframe and installed systems. The current routing process employed by EWISdesign is largely based on the manual work of expert engineers, partially supported by conventional CAD systems. As a result, the routing process is quite inefficient, error prone and unable to deliver optimal solutions. Although many harness components are selected from catalogues and the design process is largely repetitive and rule based, it has been found that none or very limited automation solutions, which can significantly decrease the workload of engineers and increase their efficiency, are currently available. In this paper, an innovative approach is proposed to solve the 3D routing automation as an optimization problem. Knowledge Based Engineering (KBE) and optimization methods are proposed to achieve minimum cost routing solutions that satisfy all relevant design rules and constraints. The proposed solution is scalable in terms of constraints, can be deployed on any type of routing environment, and, thanks to the achieved level of automation, able to reduce the process lead time drastically. The basic idea is to achieve optimal EWIS routing solutions by optimizing the position of the harnesses clamping points, which are used as way-points to route the harnesses inside the aircraft digital mock-up. The challenge to solve this optimization problem is that the number and initial value of design variables, namely the number and position of clamping points, are not known a priori. To handle this challenge, a two-step, hybrid optimization strategy has been devised. The first step, called Initialization, uses a road map based path finding method to generate a preliminary harness definition, including the required number and preliminary position of its clamping points. The second step, called Refinement, uses a conventional optimization method to move the position of the clamps and refine the preliminary harness definition aiming for the minimum cost and the satisfaction of all the design constraints. This approach has been implemented into a KBE application connected with a commercial optimization package and tested on several routing cases. The results demonstrate that the proposed method is capable of handling cases of representative geometric complexity and design constraints and delivering proper 3D harness models in full automation.