Making your wiki private is something you may require if your wiki is for personal use or if it’s strictly for internal use. To do this one small addition is required in your LocalSettings.php file, add the text in the quote below this line of text:
$wgCacheEpoch = max( $wgCacheEpoch, gmdate( 'YmdHis', @filemtime( __FILE__ ) ) );

# This snippet prevents editing from anonymous users$wgGroupPermissions['*']['edit'] = false; # This lists ages anonymous (not-logged-in) users may see (only the log-in)$wgWhitelistRead = array("Special:Userlogin", "-", "MediaWiki:Monobook.css" );$wgGroupPermissions['*']['read'] = false; # This snippet prevents anonymous users registering$wgGroupPermissions['*']['createaccount'] = false;