How to use service renderer with context theme?
Use the theme.manager service to set the active theme to what you desire, render the block and set the original active theme back.

/** @var \Drupal\Core\Theme\ThemeInitialization $theme_initialization */
$theme_initialization = \Drupal::service('theme.initialization');
$active_theme = \Drupal::theme()-&gt;getActiveTheme();
\Drupal::theme()-&gt;setActiveTheme($theme_initialization-&gt;getActiveThemeByName($theme));
// Render your block...
\Drupal::theme()-&gt;setActiveTheme($active_theme);