How do I programmatically remove a block?
You can use hook_preprocess_html(). For example, to remove the system navigation block from the "sidebar_first" region, define the following hook in your MODULE.module:

function MODULE_preprocess_html(&amp;$variables) {
  if($variables['page']['REGION']['BLOCK'])
    $variables['page']['REGION']['BLOCK']['#access'] = FALSE;
}


with REGION = sidebar_first and BLOCK = system_navigation.