After updating my macOS version, MAMP refused to open. I downloaded the latest version on the official website and installed it. All my WordPress websites were showing the homepage properly, but not any other pages.
It looked like a permalink .htaccess issue, but the issue was httpd.conf of MAMP.
How to solve 404 on localhost MAMP when the homepage is working
If it’s not the permalinks (Go to Settings > Permalinks in the admin dashboard and re-save the permalinks to reset the URL structure.) Then it could be a configuration of MAMP.
With localhost, you need to make sure that your mod_rewrite is on.
To enable mod_rewrite on localhost in MAMP, follow these steps:
You can do this in your httpd.conf file in MAMP. MAMP > CONF > APACHE > httpd.conf.
Uncomment this line: #LoadModule rewrite_module modules/mod_rewrite.so
So it becomesLoadModule rewrite_module modules/mod_rewrite.so
Without the #. Save and restart Apache / MAMP.
That should do the trick, it did for me! Happy days.