Satellite-based Internet of Things (IoT) is recognized as a cost-effective approach for global access. In this article, we aim at improving the spectrum efficiency of satellite systems to serve a huge number of IoT devices. To this end, we present a cognitive satellite-terrestrial framework, where a multibeam satellite system with full frequency reuse shares the spectrum with terrestrial networks based on the underlay paradigm. Considering DVB-S2X recommendations, geometric configurations, and channel characteristics, we investigate a robust multigroup multicast beamforming design for the satellite-based IoT coexisting with terrestrial networks in the presence of a phase error on channel state information, and characterize the achievable rate region under the outage probability constraint for the terminal and the power consumption constraint for the satellite. Based on the concept of rate profile, an associated optimization problem is formulated to design robust beamformers and determine the Pareto boundary of the region. To solve the intractable problem, we propose a two-level iterative algorithm on the basis of joint bisection search and penalty function enabled nonsmooth optimization. In particular, we develop a Bernstein-type inequality aided method and a large deviation inequality aided method to obtain a tractable and conservative approximation for the probabilistic constraint, respectively. Numerical results are provided to confirm the validity and superiority of our proposed scheme over the existing approaches and reveal the impact of key parameters on the achievable system performance.