Remove the widgets tab from theme customizer

you can create function for theme customizer with all the settings you need:

to remove “widgets” we will need to remove the “widgets” panel.

put this code in function.php

function your_customizer( $wp_customize ) {
$wp_customize->remove_panel( 'widgets' );
}
add_action( 'customize_register', 'your_customizer' );

or if you have your own function just add:

$wp_customize->remove_panel( 'widgets' );