The multilayer perceptron (MLP) network has been widely used in various fields. However, the performance of neural networks can be heavily affected by the choice of the parameters, such as the number of hidden nodes. Here we propose a new scheme for finding an “optimal” architecture of a multilayer perceptron network for a given problem. Our philosophy is to associate a tunable gate with every node in the hidden layer. Initially, all gates remain almost closed indicating a scenario where all hidden nodes are practically rejected (i.e., non-existent). Then during training, the gates are opened depending on the ability of the nodes in reducing the objective function. In order to reduce the use of redundant (unnecessary) hidden nodes, we use an L 1 regularization on the extent of gate opening. Typically, the network begins with a large number of hidden nodes and after training, not-useful hidden nodes are deleted. The network then may further be tuned to adapt itself with the reduced architecture. The performance of the pruning method is tested on several datasets and compared with the Weight Decay and Weight Elimination regularizer methods. The results demonstrate the advantages of the proposed method on both pruning efficiency and generalization.