We can restrict a particular IP Address OR a range of them from accessing your App Service.
Go to App Service > Networking tab > Access Restrictions
Click Configure Access Restrictions > Add Rule
Choose the Deny option and Add rule .
(you can go to whatismyip.com to get your IP and putting it over there)
Testing
Now try accessing the website – You should get the following error.