Many plugins use custom fields to store data about individual posts. When a plugin adds a custom fields, its key and value (or name and value) are listed in the Custom Fields meta box. For instance, a syntax hilighting plugin may set a custom field syntax_enabled on posts that use the syntax highlighting CSS. Often the user doesn’t need to see this information and it can leed to needless confusion. Unless the user needs to edit these custm field values there’s really no need to have them listed here.
How to Hide Custom Fields
Custom fields can be hidden from the Custom Fields meta box quite easily. Typically custom fields are added by using the following code:
add_post_meta($id, 'name', 'value');
To hide your custom field from user view, simply start the name of your custom field with and underscore (“_”). So create your custom field like this:
add_post_meta($id, '_name', 'value');
Your custom field is now hidden!


Oren Yomtov
May 23, 20091:08 amIf you need to change lots of custom fields you can use my plugin to do it.
Peter
May 23, 200910:47 amI couldn’t agree more John – more plugins (I’m looking at you, all in one seo pack) should absolutely take advantage of this. Having the information displayed in 2 places only causes confusion.
The Frosty @WPCult
May 26, 20091:46 pmI am going to agree with you on this one.
Freelance Jobs
July 12, 200910:26 pmThis is what I looking for, thanks
Andrea
September 10, 200910:52 pmi am actually just starting to learn wordpress, i know somebody who just got into using wordpress, he's actually a programmer that recently started with wordpress… he told me how great it is and that i can do it too as it's fairly easy to use… that's why i'm going around looking for things to learn.. thanks for this, i'm positive we'll benefit from this…
Car hire Belfast
November 19, 20099:59 amI have worked with Joomla. Could anyone tell me which tool is better – WordPress or Joomla? I like Joomla and it is quite easy to work with Joomla. WordPress looks a little bit more complicated, isn't it?
@rarepearldesign
January 25, 20102:31 pmthanks for this information, this cleaned up my ui quite a bit!
car hire munich
February 12, 201012:56 pmfinally I have found what I am looking for! thanx!
Reino
February 17, 20104:07 pmBut how about field that are allready submitted, is there a way to hide them using the underscore method
?
Sean Jordan
June 29, 201011:16 pmAfter spending hours digging through the Plugin API reference and source code I was starting to lose hope. Then, one simple and obvious Google search, plus ten words of your blog later…
Wow. So obvious, too.