The melon fly, Zeugodacus cucurbitae (Coquillett), is a serious pest of many fruits and vegetables throughout the world. Here we have developed an easy and quick-to-prepare solid medium with multiple benefits including reductions in post-rearing waste, storage space, and labor for rearing Z. cucurbitae larvae. The development time from egg to pupa was 19.11 d when larvae were reared on the artificial diet, slightly longer than 17.73 d on pumpkin and 17.13 d on cucumber. Zeugodacus cucurbitae achieved higher values of pupal weight, length, and width on the artificial diet than two natural diet controls. The rates of pupation and adult emergence of Z. cucurbitae grown on the solid medium were comparable with those on pumpkin and cucumber. Furthermore, determined by age-specific two-sex life table method, the age-specific survival rate of Z. cucurbitae was higher on the artificial diet than cucumber but lower than pumpkin. The reproductive ability and population dynamics of Z. cucurbitae were not significantly affected on the solid medium compared with those on the two natural diets. The results suggest that our solid artificial diet is excellent for rearing Z. cucurbitae larvae in laboratory and may be used for its mass rearing, therefore facilitating its research and control.