How to block access to the bot?

hi there, welcome.

you cannot use an .htaccess file as we do not provision a server for you in that way. Netlify is really only for modern static sites - more information on that here:

that said, we you could explore redirects or access control to achieve what you are trying to do: