In particular, I don't want password-protected pages to show up in search, but it would be good to know how to exclude additional pages as well, while allowing others to still show in search.

I've seen solutions for excluding individual "posts" as well as "categories", and I've seen solutions for excluding ALL pages, but nothing for excluding individual "pages" or if there's a way to target password-protected pages in particular from showing in search results.

To clarify, I don't want anything excluded from search results for our team when they are in the admin area search, just for those visitors who are using the live website.

I assume I might be able to just use the individual "posts" exclusion solutions I've found and replace it with "page" in the code, but I'm worried about making a mistake — and if there's a PW-protected exclusion, that would be even better!

I apologize if anything seems amateur here — I am an amateur. :)

Thank you!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.