We consider the model selection of the hierarchical mixture of experts (HME). The HME is a tree-structured probabilistic model for regression and classification. The HME model has high prediction accuracy and high interpretability, however, the estimation of the parameters tends to overfit due to the complexity of the model. In order to mitigate the overfitting problem, in previous studies, several Bayesian estimation methods for the HME parameters have been proposed. In these studies, the true model that generates data is fixed. In general, however, the true model is unknown. Model selection is one of the most important and difficult problems of regression and classification. For the Bayesian HME, the model is determined by the tree structure, the form of the prior distribution and its parameters, however, only the tree structure is considered as a model parameter in previous studies. In this paper, we consider all of these as model parameters and extend the model selection method. Then, we propose a maximum a posteriori (MAP) estimation method of the Bayesian HME model selection. The approximate posterior probability of each model is calculated by the variational lower bound. We show the effectiveness of the proposed method by numerical experiments and discuss the results applied to actual data sets.