WordPressを引越したので、改めてBASIC認証を追加。
まずはWordpressディレクトリに移動して、.htaccessファイルに下記を追記。
<Files wp-login.php> AuthType Basic AuthUserFile /var/www/html/.htpasswd AuthName "Restricted" Require valid-user </Files>
次いで、.htpasswdファイルを生成。最後のfoobarはユーザー名。
$ sudo htpasswd -c .htpasswd foobar
そしてapacheを再起動
$ sudo systemctl restart apache2
以降、ログインする時にBASIC認証が必要。

BASIC認証を追加