Literature survey shows that convolutional neural network (CNN)‐based pretrained models have been successfully employed to diagnose and detect childhood pneumonia using chest X‐rays (CXR). However, most of the existing methods are prone to imbalance problems, which become even more significant in medical image classification for example most importantly childhood pneumonia classification using CXR. This is due to the fact that some classes in childhood pneumonia have a very little support in the training dataset. Additionally, though the existing methods have reported better performances for training and testing, in most of the test cases the existing models will not be effective on variants of the childhood pneumonia CXR images or CXR samples from a new pediatric patient. In addition, the models may be effective in detecting latent stage pediatric pneumonia but not show better performances for CXR samples from pediatric patients who are early stage, sick but not pneumonia, sick with other lung diseases, and so on. Generalization is an important term to be considered while designing a pneumonia classifier that can perform well on completely unseen pneumonia CXR datasets. This article presents a cost‐sensitive large‐scale learning with stacked ensemble meta‐classifier and transfer learning‐based deep feature fusion approach for pediatric pneumonia classification using CXR. With the aim to identify the importance among the classes of pneumonia, the larger cost items are introduced based on the class‐imbalance degree during the backpropogation learning methodology in transfer learning models such as Xception, InceptionResNetV2, DenseNet201, and NASNetMobile. Next, the features from the penultimate layer (global average pooling) of Xception, InceptionResNetV2, DenseNet201, and NASNetMobile were extracted and dimensionality of the extracted features were reduced using kernel principal component analysis (KPCA). The reduced features were fused together and passed into a stacked ensemble meta‐classifier for classifying the CXR into either pneumonia or normal. A stacked ensemble meta‐classifier is a two stage approach in which the first stage employs random forest and support vector machine (SVM) for prediction and followed by logistic regression for classification. Experiments of the proposed model were done on publicly available benchmark pediatric pneumonia classification CXR dataset. In addition, the experiments for existing methods as well as various cost‐insensitive models were conducted. In all the experiments, the proposed method has achieved better performances compared to the existing methods as well as various cost‐insensitive models. In particular, the proposed method showed 6% improvement in precision, 10% improvement in recall, 9% improvement in F1 score with less misclassification costs (0.0321) and accuracy (96.8%). Most importantly, the proposed method is insensitive to the imbalance data and more effective to handle variants of the childhood pneumonia CXR images. Thus, the proposed approach can...