Title: password protecting custom fields
Last modified: August 19, 2016

---

# password protecting custom fields

 *  [alyssian](https://wordpress.org/support/users/alyssian/)
 * (@alyssian)
 * [15 years, 4 months ago](https://wordpress.org/support/topic/password-protecting-custom-fields/)
 * hi there,
 * the thumbnails on this page are a custom field. the page is password protected,
   but as you can see, the password protection is not working on the custom field:
   [http://kakadunativeplants.com.au/recent-projects](http://kakadunativeplants.com.au/recent-projects)
 * how can i password protect the custom field too?
 * i found this piece of code on a blog, but i don’t know where to place it within
   my page template php code (i’ve tried a few different spots, but nothing has 
   worked):
 * <?php
    if ( !post_password_required() ) { echo ‘protected stuff’; } ?>
 * thanks!

The topic ‘password protecting custom fields’ is closed to new replies.

## Tags

 * [custom fields](https://wordpress.org/support/topic-tag/custom-fields/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 0 replies
 * 1 participant
 * Last reply from: [alyssian](https://wordpress.org/support/users/alyssian/)
 * Last activity: [15 years, 4 months ago](https://wordpress.org/support/topic/password-protecting-custom-fields/)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
