Unsearchable Directories

I have a directory that has already been created and I want to make it unsearchable by Google or any search engine for that matter. I only want the directory to be unsearchable, not my entire website.

If that’s not possible, I would like to make that directory private and inaccessible unless you have a username a password. How do I do either one of these things?

Thank you!

Some search engines don’t respect the robots.txt directives, so that’d be no guarantee.

Password protecting it would block unwanted access.

Thanks so much!