Check this plugin – https://wordpress.org/plugins/jf3-maintenance-mode/
This plugin is intended primarily for designers / developers that need to allow clients to preview sites before being available to the general public or to temporarily hide your WordPress site while undergoing major updates.