Access the Shopify Admin panel.
Go to Online Store, then select Themes.
Find your active theme and click "Customize".
In the theme editor, locate and click on "App embeds" icon in the left sidebar.
In the search bar, type "Hide Express Checkout".
Find the "Hide Express Checkout" app in the list.
Toggle the switch to enable it.
Click "Save" to apply the changes.
After completing these steps, the express checkout buttons should be hidden on both the Cart and Product pages.