Learning MacOS recently, and couldn’t find some hidden files, i.e. .htaccess
To fix this, easy.
Open Terminal, and paste the following in (both lines together), and press enter. Done.
defaults write com.apple.finder AppleShowAllFiles TRUE killall Finder
To reverse the operation and re-hide them, change TRUE to FALSE.