How can I restrict access to a widget to admins only?

Simply add the following on top of your code:

if ( ! current_user_can( 'manage_options' ) );
    return;