The first step in resolving Power BI Service refresh failures that do not occur on the Desktop is to check the error information in the Power BI Service under the dataset settings. The error message will frequently lead you to the cause of the problem, whether that's an authentication issue, no gateway connections, or timeout limits. While the Power BI Desktop is with you, the Service is in the cloud and now requires adequate configuration for either the on-premises data source or the cloud-based data.
The most prevalent of these would be the misconfigured or missing On-premises Data Gateway. Ensure that the gateway is online and properly mapped to your dataset's data sources. Under the dataset settings, the following should be noted: "Data source credentials." Re-enter these if necessary, especially after changes have been made to credentials or security settings.
Above all, look at service-specific limitations, such as query timeout limits (maximum 2 hours), size constraints (dataset size limits in shared vs. Premium capacity), or unsupported data connectors in the cloud. For deeper debugging, Query Diagnostics can be used on a Desktop, Gateway logs can be monitored, and query logging at the source (e.g., SQL Profiler for SQL Server) can be practiced. Most of the time, one has to configure their Power BI Desktop environment to match that of Power BI Service because of differences.