It is to provide a novel heterocyclic compound which has the effect of inducing degradation of interleukin-1 receptor-associated kinase-M (IRAK-M) protein and is expected to be useful for the prevention/treatment of cancer, fibrosis, infectious diseases, etc. The present invention provides a compound represented by the following formula (I) or a pharmaceutically acceptable salt thereof.