The effect of core pressure gradient just inside the top of the pedestal on the energy loss due to type-I edge localized modes (ELMs) is studied. An analysis of the experimental data from JT-60U shows that the ELM energy loss normalized by the pedestal stored energy increases with the pressure gradient inside the top of the pedestal normalized by the pedestal pressure gradient. The dependence of normalized ELM energy loss on the normalized pressure gradient inside the top of the pedestal is similar to that predicted by the integrated code TOPICS-IB. The stability of linear ideal MHD modes is analysed using experimental profiles. It is found that the steep core pressure gradient inside the top of the pedestal broadens the eigenfunction profiles of unstable modes inwards. The TOPICS-IB simulation predicted that this broadening can enhance the ELM energy loss.